@@ -13,7 +13,7 @@ use crate::docbuilder::Limits;
1313use crate :: error:: Result ;
1414use crate :: repositories:: RepositoryStatsUpdater ;
1515use crate :: storage:: {
16- CompressionAlgorithm , RustdocJsonFormatVersion , compress, rustdoc_archive_path,
16+ CompressionAlgorithm , RustdocJsonFormatVersion , compress, get_file_list , rustdoc_archive_path,
1717 rustdoc_json_path, source_archive_path,
1818} ;
1919use crate :: utils:: {
@@ -24,6 +24,7 @@ use crate::{AsyncStorage, Config, Context, InstanceMetrics, RegistryApi, Storage
2424use crate :: { db:: blacklist:: is_blacklisted, utils:: MetadataPackage } ;
2525use anyhow:: { Context as _, Error , anyhow, bail} ;
2626use docsrs_metadata:: { BuildTargets , DEFAULT_TARGETS , HOST_TARGET , Metadata } ;
27+ use itertools:: Itertools as _;
2728use regex:: Regex ;
2829use rustwide:: cmd:: { Command , CommandError , SandboxBuilder , SandboxImage } ;
2930use rustwide:: logging:: { self , LogStorage } ;
@@ -890,7 +891,16 @@ impl RustwideBuilder {
890891 } )
891892 . next ( )
892893 . ok_or_else ( || {
893- anyhow ! ( "no JSON file found in target/doc after successful rustdoc json build" )
894+ anyhow ! (
895+ "no JSON file found in target/doc after successful rustdoc json build.\n \
896+ search directory: {}\n \
897+ files: {:?}",
898+ json_dir. to_string_lossy( ) ,
899+ get_file_list( & json_dir)
900+ . filter_map( Result :: ok)
901+ . map( |p| p. to_string_lossy( ) . to_string( ) )
902+ . collect_vec( ) ,
903+ )
894904 } ) ?;
895905
896906 let format_version = {
@@ -1282,6 +1292,7 @@ mod tests {
12821292 use crate :: storage:: CompressionAlgorithm ;
12831293 use crate :: test:: { AxumRouterTestExt , TestEnvironment , wrapper} ;
12841294 use std:: { io, iter} ;
1295+ use test_case:: test_case;
12851296
12861297 fn get_features (
12871298 env : & TestEnvironment ,
@@ -1700,12 +1711,12 @@ mod tests {
17001711 } ) ;
17011712 }
17021713
1703- #[ test]
1714+ #[ test_case( "scsys-macros" , "0.2.6" ) ]
1715+ #[ test_case( "scsys-derive" , "0.2.6" ) ]
1716+ #[ test_case( "thiserror-impl" , "1.0.26" ) ]
17041717 #[ ignore]
1705- fn test_proc_macro ( ) {
1718+ fn test_proc_macro ( crate_ : & str , version : & str ) {
17061719 wrapper ( |env| {
1707- let crate_ = "thiserror-impl" ;
1708- let version = "1.0.26" ;
17091720 let mut builder = RustwideBuilder :: init ( env) . unwrap ( ) ;
17101721 builder. update_toolchain ( ) ?;
17111722 assert ! (
0 commit comments