@@ -114,17 +114,6 @@ func key(prefix string, i int) string {
114
114
return prefix + fmt .Sprintf ("%04d" , i )
115
115
}
116
116
117
- func buildTestTable (t * testing.T , prefix string , n int , opts table.Options ) * table.Table {
118
- y .AssertTrue (n <= 10000 )
119
- keyValues := make ([][]string , n )
120
- for i := 0 ; i < n ; i ++ {
121
- k := key (prefix , i )
122
- v := fmt .Sprintf ("%d" , i )
123
- keyValues [i ] = []string {k , v }
124
- }
125
- return buildTable (t , keyValues , opts )
126
- }
127
-
128
117
// TODO - Move these to somewhere where table package can also use it.
129
118
// keyValues is n by 2 where n is number of pairs.
130
119
func buildTable (t * testing.T , keyValues [][]string , bopts table.Options ) * table.Table {
@@ -162,6 +151,17 @@ func TestOverlappingKeyRangeError(t *testing.T) {
162
151
// linter, I realized that the runCompactDef function below always returns error.
163
152
t .Skip ()
164
153
154
+ buildTestTable := func (t * testing.T , prefix string , n int , opts table.Options ) * table.Table {
155
+ y .AssertTrue (n <= 10000 )
156
+ keyValues := make ([][]string , n )
157
+ for i := 0 ; i < n ; i ++ {
158
+ k := key (prefix , i )
159
+ v := fmt .Sprintf ("%d" , i )
160
+ keyValues [i ] = []string {k , v }
161
+ }
162
+ return buildTable (t , keyValues , opts )
163
+ }
164
+
165
165
dir , err := os .MkdirTemp ("" , "badger-test" )
166
166
require .NoError (t , err )
167
167
defer removeDir (dir )
0 commit comments