@@ -337,6 +337,7 @@ struct AllTypes {
337337 traits : FxHashSet < ItemEntry > ,
338338 macros : FxHashSet < ItemEntry > ,
339339 functions : FxHashSet < ItemEntry > ,
340+ tests : FxHashSet < ItemEntry > ,
340341 type_aliases : FxHashSet < ItemEntry > ,
341342 opaque_tys : FxHashSet < ItemEntry > ,
342343 statics : FxHashSet < ItemEntry > ,
@@ -357,6 +358,7 @@ impl AllTypes {
357358 traits : new_set ( 100 ) ,
358359 macros : new_set ( 100 ) ,
359360 functions : new_set ( 100 ) ,
361+ tests : new_set ( 100 ) ,
360362 type_aliases : new_set ( 100 ) ,
361363 opaque_tys : new_set ( 100 ) ,
362364 statics : new_set ( 100 ) ,
@@ -381,6 +383,7 @@ impl AllTypes {
381383 ItemType :: Trait => self . traits . insert ( ItemEntry :: new ( new_url, name) ) ,
382384 ItemType :: Macro => self . macros . insert ( ItemEntry :: new ( new_url, name) ) ,
383385 ItemType :: Function => self . functions . insert ( ItemEntry :: new ( new_url, name) ) ,
386+ ItemType :: Test => self . tests . insert ( ItemEntry :: new ( new_url, name) ) ,
384387 ItemType :: TypeAlias => self . type_aliases . insert ( ItemEntry :: new ( new_url, name) ) ,
385388 ItemType :: OpaqueTy => self . opaque_tys . insert ( ItemEntry :: new ( new_url, name) ) ,
386389 ItemType :: Static => self . statics . insert ( ItemEntry :: new ( new_url, name) ) ,
@@ -419,6 +422,9 @@ impl AllTypes {
419422 if !self . functions . is_empty ( ) {
420423 sections. insert ( ItemSection :: Functions ) ;
421424 }
425+ if !self . tests . is_empty ( ) {
426+ sections. insert ( ItemSection :: Tests ) ;
427+ }
422428 if !self . type_aliases . is_empty ( ) {
423429 sections. insert ( ItemSection :: TypeAliases ) ;
424430 }
@@ -476,6 +482,7 @@ impl AllTypes {
476482 print_entries ( f, & self . attribute_macros , ItemSection :: AttributeMacros ) ;
477483 print_entries ( f, & self . derive_macros , ItemSection :: DeriveMacros ) ;
478484 print_entries ( f, & self . functions , ItemSection :: Functions ) ;
485+ print_entries ( f, & self . tests , ItemSection :: Tests ) ;
479486 print_entries ( f, & self . type_aliases , ItemSection :: TypeAliases ) ;
480487 print_entries ( f, & self . trait_aliases , ItemSection :: TraitAliases ) ;
481488 print_entries ( f, & self . opaque_tys , ItemSection :: OpaqueTypes ) ;
@@ -2149,6 +2156,7 @@ pub(crate) enum ItemSection {
21492156 Statics ,
21502157 Traits ,
21512158 Functions ,
2159+ Tests ,
21522160 TypeAliases ,
21532161 Unions ,
21542162 Implementations ,
@@ -2182,6 +2190,7 @@ impl ItemSection {
21822190 Statics ,
21832191 Traits ,
21842192 Functions ,
2193+ Tests ,
21852194 TypeAliases ,
21862195 Unions ,
21872196 Implementations ,
@@ -2208,6 +2217,7 @@ impl ItemSection {
22082217 Self :: Unions => "unions" ,
22092218 Self :: Enums => "enums" ,
22102219 Self :: Functions => "functions" ,
2220+ Self :: Tests => "tests" ,
22112221 Self :: TypeAliases => "types" ,
22122222 Self :: Statics => "statics" ,
22132223 Self :: Constants => "constants" ,
@@ -2238,6 +2248,7 @@ impl ItemSection {
22382248 Self :: Unions => "Unions" ,
22392249 Self :: Enums => "Enums" ,
22402250 Self :: Functions => "Functions" ,
2251+ Self :: Tests => "Tests" ,
22412252 Self :: TypeAliases => "Type Aliases" ,
22422253 Self :: Statics => "Statics" ,
22432254 Self :: Constants => "Constants" ,
@@ -2269,6 +2280,7 @@ fn item_ty_to_section(ty: ItemType) -> ItemSection {
22692280 ItemType :: Union => ItemSection :: Unions ,
22702281 ItemType :: Enum => ItemSection :: Enums ,
22712282 ItemType :: Function => ItemSection :: Functions ,
2283+ ItemType :: Test => ItemSection :: Tests ,
22722284 ItemType :: TypeAlias => ItemSection :: TypeAliases ,
22732285 ItemType :: Static => ItemSection :: Statics ,
22742286 ItemType :: Constant => ItemSection :: Constants ,
0 commit comments