37 const std::filesystem::path boardPath =
42 const std::filesystem::path outputRoot =
43 std::filesystem::temp_directory_path() /
"kicad_pdf_single_doc_test";
44 const std::filesystem::path outputPath =
45 outputRoot /
"Assembly" /
"Assembly_output.pdf";
47 if( std::filesystem::exists( outputRoot ) )
48 std::filesystem::remove_all( outputRoot );
50 auto pdfJob = std::make_unique<JOB_EXPORT_PCB_PDF>();
51 pdfJob->m_filename = wxString::FromUTF8( boardPath.string().c_str() );
52 pdfJob->SetConfiguredOutputPath( wxString::FromUTF8( outputPath.string().c_str() ) );
53 pdfJob->m_plotDrawingSheet =
false;
54 pdfJob->m_pdfSingle =
true;
56 pdfJob->m_plotLayerSequence =
LSEQ( {
F_Cu } );
61 BOOST_CHECK( std::filesystem::exists( outputPath ) );
62 BOOST_CHECK( std::filesystem::is_regular_file( outputPath ) );
64 const std::filesystem::path nestedPdf =
65 outputPath / ( boardPath.stem().
string() +
".pdf" );
66 BOOST_CHECK( !std::filesystem::exists( nestedPdf ) );
68 std::filesystem::remove_all( outputRoot );
wxString result
Test unit parsing edge cases and error handling.
BOOST_CHECK_EQUAL(result, "25.4")