File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -1735,6 +1735,31 @@ mod tests {
1735
1735
let source_archive = source_archive_path ( crate_, version) ;
1736
1736
assert ! ( storage. exists( & source_archive) ?) ;
1737
1737
1738
+ let path = rustdoc_json_path (
1739
+ crate_,
1740
+ version,
1741
+ HOST_TARGET ,
1742
+ RustdocJsonFormatVersion :: Latest ,
1743
+ ) ;
1744
+ assert ! ( storage. exists( & path) ?) ;
1745
+ assert ! ( storage. get_public_access( & path) ?) ;
1746
+
1747
+ let json_prefix = format ! ( "rustdoc-json/{crate_}/{version}/{}/" , HOST_TARGET ) ;
1748
+ let mut json_files: Vec < _ > = storage
1749
+ . list_prefix ( & json_prefix)
1750
+ . filter_map ( |res| res. ok ( ) )
1751
+ . map ( |f| f. strip_prefix ( & json_prefix) . unwrap ( ) . to_owned ( ) )
1752
+ . collect ( ) ;
1753
+ json_files. sort ( ) ;
1754
+ dbg ! ( & json_files) ;
1755
+ assert_eq ! (
1756
+ json_files,
1757
+ vec![
1758
+ format!( "empty-library_1.0.0_{HOST_TARGET}_45.json.zst" ) ,
1759
+ format!( "empty-library_1.0.0_{HOST_TARGET}_latest.json.zst" ) ,
1760
+ ]
1761
+ ) ;
1762
+
1738
1763
Ok ( ( ) )
1739
1764
} ) ;
1740
1765
}
You can’t perform that action at this time.
0 commit comments