| 1 | #cxx . . $ `<file>/tests/convert/convert_tests.cpp`/include <catch2/catch_test_macros.hpp> |
| 2 | |
| 3 | #include "convert/convert.hpp"cxx . . $ `<file>/src/LibBGCode/convert/convert.hpp`/ |
| 4 | |
| 5 | #include <fstream> |
| 6 | #include <iostream> |
| 7 | |
| 8 | #include <boost/nowide/cstdio.hpp> |
| 9 | |
| 10 | using namespace bgcodecxx . . $ bgcode/::core; |
| 11 | using namespace bgcodecxx . . $ bgcode/::binarize; |
| 12 | using namespace bgcodecxx . . $ bgcode/::convert; |
| 13 | |
| 14 | class ScopedFilecxx . . $ ScopedFile# |
| 15 | { |
| 16 | public: |
| 17 | explicit ScopedFilecxx . . $ ScopedFile#ScopedFile(8d4262d45fc644ab).(FILEcxx . . $ FILE#* file) : m_filecxx . . $ ScopedFile#m_file.(file) {} |
| 18 | ~cxx . . $ ScopedFile#`~ScopedFile`(ced63f7c635d850d).ScopedFilecxx . . $ ScopedFile#() { if (m_filecxx . . $ ScopedFile#m_file. != nullptr) fclose(m_filecxx . . $ ScopedFile#m_file.); } |
| 19 | private: |
| 20 | FILEcxx . . $ FILE#* m_filecxx . . $ ScopedFile#m_file.{ nullptr }; |
| 21 | }; |
| 22 | |
| 23 | void binary_to_asciicxx . . $ binary_to_ascii(c3ca1c130ce09c52).(const stdcxx . . $ std/::stringcxx . . $ std/string#& src_filename, const stdcxx . . $ std/::stringcxx . . $ std/string#& dst_filename) |
| 24 | { |
| 25 | // Open source file |
| 26 | FILEcxx . . $ FILE#* src_file = boostcxx . . $ boost/::nowidecxx . . $ boost/nowide/::fopencxx . . $ boost/nowide/fopen(82ec0787cd37e0a3).(src_filename.c_strcxx . . $ std/__cxx11/basic_string#c_str(8e614c7de0b1573e).(), "rb"); |
| 27 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(src_file != nullptr); |
| 28 | ScopedFilecxx . . $ ScopedFile# scoped_src_filecxx . . $ ScopedFile#ScopedFile(8d4262d45fc644ab).(src_file); |
| 29 | |
| 30 | // Open destination file |
| 31 | FILEcxx . . $ FILE#* dst_file = boostcxx . . $ boost/::nowidecxx . . $ boost/nowide/::fopencxx . . $ boost/nowide/fopen(82ec0787cd37e0a3).(dst_filename.c_strcxx . . $ std/__cxx11/basic_string#c_str(8e614c7de0b1573e).(), "wb"); |
| 32 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(dst_file != nullptr); |
| 33 | ScopedFilecxx . . $ ScopedFile# scoped_dst_filecxx . . $ ScopedFile#ScopedFile(8d4262d45fc644ab).(dst_file); |
| 34 | |
| 35 | // Perform conversion |
| 36 | EResultcxx . . $ bgcode/core/EResult# res = from_binary_to_asciicxx . . $ bgcode/convert/from_binary_to_ascii(b67601911a29e706).(*src_file, *dst_file, true); |
| 37 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(res == EResult::Success); |
| 38 | } |
| 39 | |
| 40 | void ascii_to_binarycxx . . $ ascii_to_binary(15c847bcac8bd7c8).(const stdcxx . . $ std/::stringcxx . . $ std/string#& src_filename, const stdcxx . . $ std/::stringcxx . . $ std/string#& dst_filename, const BinarizerConfigcxx . . $ bgcode/binarize/BinarizerConfig#& config) |
| 41 | { |
| 42 | // Open source file |
| 43 | FILEcxx . . $ FILE#* src_file = boostcxx . . $ boost/::nowidecxx . . $ boost/nowide/::fopencxx . . $ boost/nowide/fopen(82ec0787cd37e0a3).(src_filename.c_strcxx . . $ std/__cxx11/basic_string#c_str(8e614c7de0b1573e).(), "rb"); |
| 44 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(src_file != nullptr); |
| 45 | ScopedFilecxx . . $ ScopedFile# ab_scoped_src_filecxx . . $ ScopedFile#ScopedFile(8d4262d45fc644ab).(src_file); |
| 46 | |
| 47 | // Open destination file |
| 48 | FILEcxx . . $ FILE#* dst_file = boostcxx . . $ boost/::nowidecxx . . $ boost/nowide/::fopencxx . . $ boost/nowide/fopen(82ec0787cd37e0a3).(dst_filename.c_strcxx . . $ std/__cxx11/basic_string#c_str(8e614c7de0b1573e).(), "wb"); |
| 49 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(dst_file != nullptr); |
| 50 | ScopedFilecxx . . $ ScopedFile# ab_scoped_dst_filecxx . . $ ScopedFile#ScopedFile(8d4262d45fc644ab).(dst_file); |
| 51 | |
| 52 | // Perform conversion |
| 53 | EResultcxx . . $ bgcode/core/EResult# res = from_ascii_to_binarycxx . . $ bgcode/convert/from_ascii_to_binary(7b65e296ceea934d).(*src_file, *dst_file, config); |
| 54 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(res == EResult::Success); |
| 55 | } |
| 56 | |
| 57 | void compare_binary_filescxx . . $ compare_binary_files(c3ca1c130ce09c52).(const stdcxx . . $ std/::stringcxx . . $ std/string#& filename1, const stdcxx . . $ std/::stringcxx . . $ std/string#& filename2) |
| 58 | { |
| 59 | // Open file 1 |
| 60 | FILEcxx . . $ FILE#* file1 = boostcxx . . $ boost/::nowidecxx . . $ boost/nowide/::fopencxx . . $ boost/nowide/fopen(82ec0787cd37e0a3).(filename1.c_strcxx . . $ std/__cxx11/basic_string#c_str(8e614c7de0b1573e).(), "rb"); |
| 61 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(file1 != nullptr); |
| 62 | ScopedFilecxx . . $ ScopedFile# scoped_file1cxx . . $ ScopedFile#ScopedFile(8d4262d45fc644ab).(file1); |
| 63 | |
| 64 | // Open file 2 |
| 65 | FILEcxx . . $ FILE#* file2 = boostcxx . . $ boost/::nowidecxx . . $ boost/nowide/::fopencxx . . $ boost/nowide/fopen(82ec0787cd37e0a3).(filename2.c_strcxx . . $ std/__cxx11/basic_string#c_str(8e614c7de0b1573e).(), "rb"); |
| 66 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(file2 != nullptr); |
| 67 | ScopedFilecxx . . $ ScopedFile# scoped_file2cxx . . $ ScopedFile#ScopedFile(8d4262d45fc644ab).(file2); |
| 68 | |
| 69 | // Compare file sizes |
| 70 | fseek(file1, 0, SEEK_ENDcxx . . $ `<external>/232824719582829767/stdio.h:116:9`!); |
| 71 | const long file1_size = ftell(file1); |
| 72 | rewind(file1); |
| 73 | fseek(file2, 0, SEEK_ENDcxx . . $ `<external>/232824719582829767/stdio.h:116:9`!); |
| 74 | const long file2_size = ftell(file2); |
| 75 | rewind(file2); |
| 76 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(file1_size == file2_size); |
| 77 | |
| 78 | // Compare file contents |
| 79 | static const size_t buf_size = 4096; |
| 80 | stdcxx . . $ std/::vectorcxx . . $ std/vector#<uint8_tcxx . . $ uint8_t#> buf1cxx . . $ std/vector#vector(83fdeebbe0501a83).(buf_size); |
| 81 | stdcxx . . $ std/::vectorcxx . . $ std/vector#<uint8_tcxx . . $ uint8_t#> buf2cxx . . $ std/vector#vector(83fdeebbe0501a83).(buf_size); |
| 82 | do { |
| 83 | const size_t r1 = fread(buf1.datacxx . . $ std/vector#data(258ee1c9e0a18a5c).(), 1, buf_size, file1); |
| 84 | const size_t r2 = fread(buf2.datacxx . . $ std/vector#data(258ee1c9e0a18a5c).(), 1, buf_size, file2); |
| 85 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(r1 == r2); |
| 86 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(buf1 == buf2); |
| 87 | } while (!feof(file1) || !feof(file2)); |
| 88 | } |
| 89 | |
| 90 | void compare_text_filescxx . . $ compare_text_files(c3ca1c130ce09c52).(const stdcxx . . $ std/::stringcxx . . $ std/string#& filename1, const stdcxx . . $ std/::stringcxx . . $ std/string#& filename2) |
| 91 | { |
| 92 | // Open files |
| 93 | stdcxx . . $ std/::ifstreamcxx . . $ std/ifstream# file1cxx . . $ std/basic_ifstream#basic_ifstream(be6c264dafcf0985).(filename1, stdcxx . . $ std/::ioscxx . . $ std/ios#::binarycxx . . $ std/ios_base#binary.); |
| 94 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(file1.good()); |
| 95 | stdcxx . . $ std/::ifstreamcxx . . $ std/ifstream# file2cxx . . $ std/basic_ifstream#basic_ifstream(be6c264dafcf0985).(filename2, stdcxx . . $ std/::ioscxx . . $ std/ios#::binarycxx . . $ std/ios_base#binary.); |
| 96 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(file1.good()); |
| 97 | // Compare file contents |
| 98 | stdcxx . . $ std/::stringcxx . . $ std/string# line1cxx . . $ std/__cxx11/basic_string#basic_string(925dcc5e17f50391).; |
| 99 | stdcxx . . $ std/::stringcxx . . $ std/string# line2cxx . . $ std/__cxx11/basic_string#basic_string(925dcc5e17f50391).; |
| 100 | while (stdcxx . . $ std/::getlinecxx . . $ std/getline(4ec722ed0b69c2ab).(file1, line1)) { |
| 101 | stdcxx . . $ std/::getlinecxx . . $ std/getline(4ec722ed0b69c2ab).(file2, line2); |
| 102 | if (!line1.emptycxx . . $ std/__cxx11/basic_string#empty(3482b152b9333168).() && line1.backcxx . . $ std/__cxx11/basic_string#back(da5fe8e926c570ad).() == '\r') line1.pop_backcxx . . $ std/__cxx11/basic_string#pop_back(ced63f7c635d850d).(); |
| 103 | if (!line2.emptycxx . . $ std/__cxx11/basic_string#empty(3482b152b9333168).() && line2.backcxx . . $ std/__cxx11/basic_string#back(da5fe8e926c570ad).() == '\r') line2.pop_backcxx . . $ std/__cxx11/basic_string#pop_back(ced63f7c635d850d).(); |
| 104 | REQUIREcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:127:11`!(line1 == line2); |
| 105 | } |
| 106 | } |
| 107 | |
| 108 | TEST_CASEcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:144:11`!("Convert from binary to ascii", "[Convert]") |
| 109 | { |
| 110 | stdcxx . . $ std/::coutcxx . . $ std/cout. <<cxx . . $ std/`operator<<`(efaf8c13fc75f3c7). "\nTEST: Convert from binary to ascii\n"; |
| 111 | |
| 112 | const stdcxx . . $ std/::stringcxx . . $ std/string# src_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_b.bgcode"; |
| 113 | const stdcxx . . $ std/::stringcxx . . $ std/string# dst_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_b.gcode"; |
| 114 | const stdcxx . . $ std/::stringcxx . . $ std/string# check_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_b_ref.gcode"; |
| 115 | |
| 116 | // convert from binary to ascii |
| 117 | binary_to_asciicxx . . $ binary_to_ascii(c3ca1c130ce09c52).(src_filename, dst_filename); |
| 118 | // compare results |
| 119 | compare_text_filescxx . . $ compare_text_files(c3ca1c130ce09c52).(dst_filename, check_filename); |
| 120 | } |
| 121 | |
| 122 | TEST_CASEcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:144:11`!("Convert from ascii to binary", "[Convert]") |
| 123 | { |
| 124 | stdcxx . . $ std/::coutcxx . . $ std/cout. <<cxx . . $ std/`operator<<`(efaf8c13fc75f3c7). "\nTEST: Convert from ascii to binary\n"; |
| 125 | |
| 126 | // convert from ascii to binary |
| 127 | const stdcxx . . $ std/::stringcxx . . $ std/string# ab_src_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_a.gcode"; |
| 128 | const stdcxx . . $ std/::stringcxx . . $ std/string# ab_dst_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_a.bgcode"; |
| 129 | BinarizerConfigcxx . . $ bgcode/binarize/BinarizerConfig# config; |
| 130 | config.checksumcxx . . $ bgcode/binarize/BinarizerConfig#checksum. = EChecksumTypecxx . . $ bgcode/core/EChecksumType#::CRC32cxx . . $ bgcode/core/EChecksumType#CRC32.; |
| 131 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..file_metadatacxx . . $ bgcode/binarize/BinarizerConfig#Compression#file_metadata. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Nonecxx . . $ bgcode/core/ECompressionType#None.; |
| 132 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..print_metadatacxx . . $ bgcode/binarize/BinarizerConfig#Compression#print_metadata. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Nonecxx . . $ bgcode/core/ECompressionType#None.; |
| 133 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..printer_metadatacxx . . $ bgcode/binarize/BinarizerConfig#Compression#printer_metadata. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Nonecxx . . $ bgcode/core/ECompressionType#None.; |
| 134 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..slicer_metadatacxx . . $ bgcode/binarize/BinarizerConfig#Compression#slicer_metadata. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Deflatecxx . . $ bgcode/core/ECompressionType#Deflate.; |
| 135 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..gcodecxx . . $ bgcode/binarize/BinarizerConfig#Compression#gcode. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Heatshrink_12_4cxx . . $ bgcode/core/ECompressionType#Heatshrink_12_4.; |
| 136 | config.gcode_encodingcxx . . $ bgcode/binarize/BinarizerConfig#gcode_encoding. = EGCodeEncodingTypecxx . . $ bgcode/core/EGCodeEncodingType#::MeatPackCommentscxx . . $ bgcode/core/EGCodeEncodingType#MeatPackComments.; |
| 137 | config.metadata_encodingcxx . . $ bgcode/binarize/BinarizerConfig#metadata_encoding. = EMetadataEncodingTypecxx . . $ bgcode/core/EMetadataEncodingType#::INIcxx . . $ bgcode/core/EMetadataEncodingType#INI.; |
| 138 | ascii_to_binarycxx . . $ ascii_to_binary(15c847bcac8bd7c8).(ab_src_filename, ab_dst_filename, config); |
| 139 | |
| 140 | // convert back from binary to ascii |
| 141 | const stdcxx . . $ std/::stringcxx . . $ std/string# ba_src_filename = ab_dst_filenamecxx . . $ std/__cxx11/basic_string#basic_string(a47f53d4115f6ce5).; |
| 142 | const stdcxx . . $ std/::stringcxx . . $ std/string# ba_dst_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_a_final.gcode"; |
| 143 | binary_to_asciicxx . . $ binary_to_ascii(c3ca1c130ce09c52).(ba_src_filename, ba_dst_filename); |
| 144 | |
| 145 | // compare results |
| 146 | compare_text_filescxx . . $ compare_text_files(c3ca1c130ce09c52).(ba_dst_filename, ab_src_filename); |
| 147 | } |
| 148 | |
| 149 | TEST_CASEcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:144:11`!("Convert from binary to ascii PS 2.8.1", "[Convert]") |
| 150 | { |
| 151 | stdcxx . . $ std/::coutcxx . . $ std/cout. <<cxx . . $ std/`operator<<`(efaf8c13fc75f3c7). "\nTEST: Convert from binary to ascii in PS 2.8.1 format\n"; |
| 152 | |
| 153 | const stdcxx . . $ std/::stringcxx . . $ std/string# src_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_ps2.8.1.bgcode"; |
| 154 | const stdcxx . . $ std/::stringcxx . . $ std/string# dst_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_ps2.8.1_out_a.gcode"; |
| 155 | const stdcxx . . $ std/::stringcxx . . $ std/string# check_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_ps2.8.1_ref.gcode"; |
| 156 | |
| 157 | // convert from binary to ascii |
| 158 | binary_to_asciicxx . . $ binary_to_ascii(c3ca1c130ce09c52).(src_filename, dst_filename); |
| 159 | // compare results |
| 160 | compare_text_filescxx . . $ compare_text_files(c3ca1c130ce09c52).(dst_filename, check_filename); |
| 161 | } |
| 162 | |
| 163 | TEST_CASEcxx . . $ `<external>/1821973855936310166/catch_test_macros.hpp:144:11`!("Convert from ascii to binary PS 2.8.1", "[Convert]") |
| 164 | { |
| 165 | stdcxx . . $ std/::coutcxx . . $ std/cout. <<cxx . . $ std/`operator<<`(efaf8c13fc75f3c7). "\nTEST: Convert from ascii to binary in PS 2.8.1 format\n"; |
| 166 | |
| 167 | // convert from ascii to binary |
| 168 | const stdcxx . . $ std/::stringcxx . . $ std/string# ab_src_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_ps2.8.1.gcode"; |
| 169 | const stdcxx . . $ std/::stringcxx . . $ std/string# ab_dst_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_ps2.8.1_out_b.bgcode"; |
| 170 | BinarizerConfigcxx . . $ bgcode/binarize/BinarizerConfig# config; |
| 171 | config.checksumcxx . . $ bgcode/binarize/BinarizerConfig#checksum. = EChecksumTypecxx . . $ bgcode/core/EChecksumType#::CRC32cxx . . $ bgcode/core/EChecksumType#CRC32.; |
| 172 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..file_metadatacxx . . $ bgcode/binarize/BinarizerConfig#Compression#file_metadata. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Nonecxx . . $ bgcode/core/ECompressionType#None.; |
| 173 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..print_metadatacxx . . $ bgcode/binarize/BinarizerConfig#Compression#print_metadata. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Nonecxx . . $ bgcode/core/ECompressionType#None.; |
| 174 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..printer_metadatacxx . . $ bgcode/binarize/BinarizerConfig#Compression#printer_metadata. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Nonecxx . . $ bgcode/core/ECompressionType#None.; |
| 175 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..slicer_metadatacxx . . $ bgcode/binarize/BinarizerConfig#Compression#slicer_metadata. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Deflatecxx . . $ bgcode/core/ECompressionType#Deflate.; |
| 176 | config.compressioncxx . . $ bgcode/binarize/BinarizerConfig#compression..gcodecxx . . $ bgcode/binarize/BinarizerConfig#Compression#gcode. = ECompressionTypecxx . . $ bgcode/core/ECompressionType#::Heatshrink_12_4cxx . . $ bgcode/core/ECompressionType#Heatshrink_12_4.; |
| 177 | config.gcode_encodingcxx . . $ bgcode/binarize/BinarizerConfig#gcode_encoding. = EGCodeEncodingTypecxx . . $ bgcode/core/EGCodeEncodingType#::MeatPackCommentscxx . . $ bgcode/core/EGCodeEncodingType#MeatPackComments.; |
| 178 | config.metadata_encodingcxx . . $ bgcode/binarize/BinarizerConfig#metadata_encoding. = EMetadataEncodingTypecxx . . $ bgcode/core/EMetadataEncodingType#::INIcxx . . $ bgcode/core/EMetadataEncodingType#INI.; |
| 179 | ascii_to_binarycxx . . $ ascii_to_binary(15c847bcac8bd7c8).(ab_src_filename, ab_dst_filename, config); |
| 180 | |
| 181 | // convert back from binary to ascii |
| 182 | const stdcxx . . $ std/::stringcxx . . $ std/string# ba_src_filename = ab_dst_filenamecxx . . $ std/__cxx11/basic_string#basic_string(a47f53d4115f6ce5).; |
| 183 | const stdcxx . . $ std/::stringcxx . . $ std/string# ba_dst_filename = stdcxx . . $ std/::stringcxx . . $ std/string#(TEST_DATA_DIRcxx . . $ `<built-in>:484:9`!) +cxx . . $ std/operator+(900ec9581c410ad9). "/mini_cube_ps2.8.1_final.gcode"; |
| 184 | binary_to_asciicxx . . $ binary_to_ascii(c3ca1c130ce09c52).(ba_src_filename, ba_dst_filename); |
| 185 | |
| 186 | // compare results |
| 187 | compare_text_filescxx . . $ compare_text_files(c3ca1c130ce09c52).(ba_dst_filename, ab_src_filename); |
| 188 | } |