Skip to content
This repository
Browse code

Removed headers from test tables so we don't give the impression that…

… they are needed.
  • Loading branch information...
commit 27e902cb73c53d630e6807708693712d7e483527 1 parent 36159a1
Aslak Hellesøy authored DFUK committed
37  core/src/test/java/cucumber/table/TableDifferTest.java
@@ -10,7 +10,6 @@
10 10
 
11 11
     private Table table() {
12 12
         String source =
13  
-                "| name  | email                | credits |" + EOL +
14 13
                 "| Aslak | aslak@email.com      | 123     |" + EOL +
15 14
                 "| Joe   | joe@email.com        | 234     |" + EOL +
16 15
                 "| Bryan | bryan@email.org      | 456     |" + EOL +
@@ -20,7 +19,6 @@ private Table table() {
20 19
 
21 20
     private Table otherTableWithDeletedAndInserted() {
22 21
         String source =
23  
-                "| name  | email                | credits |" + EOL +
24 22
                 "| Aslak | aslak@email.com      | 123     |" + EOL +
25 23
                 "| Doe   | joe@email.com        | 234     |" + EOL +
26 24
                 "| Foo   | schnickens@email.net | 789     |" + EOL +
@@ -30,13 +28,12 @@ private Table otherTableWithDeletedAndInserted() {
30 28
 
31 29
     private Table otherTableWithInsertedAtEnd() {
32 30
         String source =
33  
-                "| name  | email                | credits |" + EOL +
34  
-                "| Aslak | aslak@email.com      | 123     |" + EOL +
35  
-                "| Joe   | joe@email.com        | 234     |" + EOL +
36  
-                "| Bryan | bryan@email.org      | 456     |" + EOL +
37  
-                "| Ni    | ni@email.com         | 654     |" + EOL +
38  
-                "| Doe   | joe@email.com        | 234     |" + EOL +
39  
-                "| Foo   | schnickens@email.net | 789     |" + EOL;
  31
+                "| Aslak | aslak@email.com      | 123 |" + EOL +
  32
+                "| Joe   | joe@email.com        | 234 |" + EOL +
  33
+                "| Bryan | bryan@email.org      | 456 |" + EOL +
  34
+                "| Ni    | ni@email.com         | 654 |" + EOL +
  35
+                "| Doe   | joe@email.com        | 234 |" + EOL +
  36
+                "| Foo   | schnickens@email.net | 789 |" + EOL;
40 37
         return TableParser.parse(source);
41 38
     }
42 39
 
@@ -46,12 +43,11 @@ public void shouldFindDifferences() {
46 43
             new TableDiffer(table(), otherTableWithDeletedAndInserted()).calculateDiffs();
47 44
         } catch (TableDiffException e) {
48 45
             String expected =
49  
-                    "      | name | email                | credits |" + EOL +
50  
-                    "    - | Joe  | joe@email.com        | 234     |" + EOL +
51  
-                    "    + | Doe  | joe@email.com        | 234     |" + EOL +
52  
-                    "    + | Foo  | schnickens@email.net | 789     |" + EOL +
53  
-                    "      | Joe  | joe@email.com        | 234     |" + EOL +
54  
-                    "    - | Ni   | ni@email.com         | 654     |" + EOL;
  46
+                    "    - | Joe | joe@email.com        | 234 |" + EOL +
  47
+                    "    + | Doe | joe@email.com        | 234 |" + EOL +
  48
+                    "    + | Foo | schnickens@email.net | 789 |" + EOL +
  49
+                    "      | Joe | joe@email.com        | 234 |" + EOL +
  50
+                    "    - | Ni  | ni@email.com         | 654 |" + EOL;
55 51
             assertEquals(expected, pretty(e.getDiffTable()));
56 52
             throw e;
57 53
         }
@@ -63,12 +59,11 @@ public void shouldFindNewLinesAtEnd() {
63 59
             new TableDiffer(table(), otherTableWithInsertedAtEnd()).calculateDiffs();
64 60
         } catch (TableDiffException e) {
65 61
             String expected =
66  
-                    "      | name  | email                | credits |" + EOL +
67  
-                    "      | Aslak | aslak@email.com      | 123     |" + EOL +
68  
-                    "      | Joe   | joe@email.com        | 234     |" + EOL +
69  
-                    "      | Bryan | bryan@email.org      | 456     |" + EOL +
70  
-                    "    + | Doe   | joe@email.com        | 234     |" + EOL +
71  
-                    "    + | Foo   | schnickens@email.net | 789     |" + EOL;
  62
+                    "      | Aslak | aslak@email.com      | 123 |" + EOL +
  63
+                    "      | Joe   | joe@email.com        | 234 |" + EOL +
  64
+                    "      | Bryan | bryan@email.org      | 456 |" + EOL +
  65
+                    "    + | Doe   | joe@email.com        | 234 |" + EOL +
  66
+                    "    + | Foo   | schnickens@email.net | 789 |" + EOL;
72 67
             assertEquals(expected, pretty(e.getDiffTable()));
73 68
             throw e;
74 69
         }

0 notes on commit 27e902c

Please sign in to comment.
Something went wrong with that request. Please try again.