41 const std::filesystem::path boardPath =
46 const std::filesystem::path outputRoot =
47 std::filesystem::temp_directory_path() /
"kicad_pdf_single_doc_test";
48 const std::filesystem::path outputPath =
49 outputRoot /
"Assembly" /
"Assembly_output.pdf";
51 if( std::filesystem::exists( outputRoot ) )
52 std::filesystem::remove_all( outputRoot );
54 auto pdfJob = std::make_unique<JOB_EXPORT_PCB_PDF>();
55 pdfJob->m_filename = wxString::FromUTF8( boardPath.string().c_str() );
56 pdfJob->SetConfiguredOutputPath( wxString::FromUTF8( outputPath.string().c_str() ) );
57 pdfJob->m_plotDrawingSheet =
false;
58 pdfJob->m_pdfSingle =
true;
60 pdfJob->m_plotLayerSequence =
LSEQ( {
F_Cu } );
65 BOOST_CHECK( std::filesystem::exists( outputPath ) );
66 BOOST_CHECK( std::filesystem::is_regular_file( outputPath ) );
68 const std::filesystem::path nestedPdf =
69 outputPath / ( boardPath.stem().
string() +
".pdf" );
70 BOOST_CHECK( !std::filesystem::exists( nestedPdf ) );
72 std::filesystem::remove_all( outputRoot );
wxString result
Test unit parsing edge cases and error handling.
BOOST_CHECK_EQUAL(result, "25.4")