@@ -232,12 +232,12 @@ fn exact_match_first_on_queries() {
232
232
. description ( "bar_exact baz_exact" )
233
233
. expect_build ( & conn) ;
234
234
235
- :: CrateBuilder :: new ( "bar_exact " , user. id )
236
- . description ( "foo_exact baz_exact foo_exact baz_exact" )
235
+ :: CrateBuilder :: new ( "bar-exact " , user. id )
236
+ . description ( "foo_exact baz_exact foo-exact baz_exact" )
237
237
. expect_build ( & conn) ;
238
238
239
239
:: CrateBuilder :: new ( "baz_exact" , user. id )
240
- . description ( "foo_exact bar_exact foo_exact bar_exact foo_exact bar_exact" )
240
+ . description ( "foo-exact bar_exact foo-exact bar_exact foo_exact bar_exact" )
241
241
. expect_build ( & conn) ;
242
242
243
243
:: CrateBuilder :: new ( "other_exact" , user. id )
@@ -247,25 +247,25 @@ fn exact_match_first_on_queries() {
247
247
248
248
let mut req = :: req ( app, Method :: Get , "/api/v1/crates" ) ;
249
249
250
- let mut response = ok_resp ! ( middle. call( req. with_query( "q=foo_exact " ) ) ) ;
250
+ let mut response = ok_resp ! ( middle. call( req. with_query( "q=foo-exact " ) ) ) ;
251
251
let json: CrateList = :: json ( & mut response) ;
252
252
assert_eq ! ( json. meta. total, 3 ) ;
253
253
assert_eq ! ( json. crates[ 0 ] . name, "foo_exact" ) ;
254
254
assert_eq ! ( json. crates[ 1 ] . name, "baz_exact" ) ;
255
- assert_eq ! ( json. crates[ 2 ] . name, "bar_exact " ) ;
255
+ assert_eq ! ( json. crates[ 2 ] . name, "bar-exact " ) ;
256
256
257
257
let mut response = ok_resp ! ( middle. call( req. with_query( "q=bar_exact" ) ) ) ;
258
258
let json: CrateList = :: json ( & mut response) ;
259
259
assert_eq ! ( json. meta. total, 3 ) ;
260
- assert_eq ! ( json. crates[ 0 ] . name, "bar_exact " ) ;
260
+ assert_eq ! ( json. crates[ 0 ] . name, "bar-exact " ) ;
261
261
assert_eq ! ( json. crates[ 1 ] . name, "baz_exact" ) ;
262
262
assert_eq ! ( json. crates[ 2 ] . name, "foo_exact" ) ;
263
263
264
264
let mut response = ok_resp ! ( middle. call( req. with_query( "q=baz_exact" ) ) ) ;
265
265
let json: CrateList = :: json ( & mut response) ;
266
266
assert_eq ! ( json. meta. total, 3 ) ;
267
267
assert_eq ! ( json. crates[ 0 ] . name, "baz_exact" ) ;
268
- assert_eq ! ( json. crates[ 1 ] . name, "bar_exact " ) ;
268
+ assert_eq ! ( json. crates[ 1 ] . name, "bar-exact " ) ;
269
269
assert_eq ! ( json. crates[ 2 ] . name, "foo_exact" ) ;
270
270
}
271
271
0 commit comments