@@ -74,16 +74,16 @@ public void testSearchInEmptyTree(int value) {
74
74
}
75
75
76
76
private static Stream <Object []> traversalStrategies () {
77
- return Stream .of (new Object [] {SplayTree .IN_ORDER , Arrays .asList (1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 , 13 , 15 , 16 , 17 , 18 )}, new Object [] {SplayTree .PRE_ORDER , Arrays .asList (18 , 17 , 16 , 15 , 13 , 11 , 9 , 8 , 7 , 3 , 2 , 1 , 5 , 4 , 6 , 10 , 12 )},
78
- new Object [] {SplayTree .POST_ORDER , Arrays .asList (1 , 2 , 4 , 6 , 5 , 3 , 7 , 8 , 10 , 9 , 12 , 11 , 13 , 15 , 16 , 17 , 18 )});
77
+ return Stream .of (new Object [] {SplayTree .IN_ORDER , Arrays .asList (1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 , 13 , 14 , 15 , 16 , 17 , 18 , 20 )}, new Object [] {SplayTree .PRE_ORDER , Arrays .asList (20 , 17 , 14 , 13 , 11 , 9 , 8 , 7 , 3 , 2 , 1 , 5 , 4 , 6 , 10 , 12 , 15 , 16 , 18 )},
78
+ new Object [] {SplayTree .POST_ORDER , Arrays .asList (1 , 2 , 4 , 6 , 5 , 3 , 7 , 8 , 10 , 9 , 12 , 11 , 13 , 16 , 15 , 14 , 18 , 17 , 20 )});
79
79
}
80
80
81
81
private static Stream <Integer > valuesToTest () {
82
82
return Stream .of (1 , 5 , 10 , 17 , 8 , 13 , 6 , 17 , 4 , 11 , 9 , 2 , 18 , 3 , 16 , 7 , 12 );
83
83
}
84
84
85
85
private static Stream <Integer > nonExistentValues () {
86
- return Stream .of (0 , 21 , 20 , 14 );
86
+ return Stream .of (0 , 21 , 22 , 23 );
87
87
}
88
88
89
89
private SplayTree createComplexTree () {
@@ -105,6 +105,8 @@ private SplayTree createComplexTree() {
105
105
tree .insert (13 );
106
106
tree .insert (16 );
107
107
tree .insert (18 );
108
+ tree .insert (14 );
109
+ tree .insert (20 );
108
110
return tree ;
109
111
}
110
112
}
0 commit comments