1
0
mirror of https://github.com/woo-j/zint.git synced 2024-12-25 09:33:56 +03:00
zint/backend/tests
2019-11-28 19:15:29 +00:00
..
cmake/Modules New files 2019-09-01 21:09:47 +01:00
data KOREAPOST missing from is_linear; tests update 2019-10-14 09:49:15 +01:00
tools ECI conversion for GRIDMATRIX; GB 2312 LIBICONV port 2019-11-28 19:15:29 +00:00
CMakeLists.txt ECI conversion for GRIDMATRIX; GB 2312 LIBICONV port 2019-11-28 19:15:29 +00:00
README Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_channel.c KOREAPOST missing from is_linear; tests update 2019-10-14 09:49:15 +01:00
test_common.c Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_composite.c EAN128_CC ecc, cc_width, rows and alignment adjustments 2019-11-05 14:16:48 +00:00
test_dmatrix.c Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_eci.c Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_gb2312_tab.h ECI conversion for GRIDMATRIX; GB 2312 LIBICONV port 2019-11-28 19:15:29 +00:00
test_gb2312.c ECI conversion for GRIDMATRIX; GB 2312 LIBICONV port 2019-11-28 19:15:29 +00:00
test_gs1.c Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_imail.c KOREAPOST missing from is_linear; tests update 2019-10-14 09:49:15 +01:00
test_library.c Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_mailmark.c KOREAPOST missing from is_linear; tests update 2019-10-14 09:49:15 +01:00
test_maxicode.c KOREAPOST missing from is_linear; tests update 2019-10-14 09:49:15 +01:00
test_postal.c Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_qr.c Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_raster.c EANX/UPCA/UPCE_CHK handling + various raster/vector fixes; ISBNX add-ons 2019-11-11 21:38:21 +00:00
test_rss.c EAN128_CC ecc, cc_width, rows and alignment adjustments 2019-11-05 14:16:48 +00:00
test_sjis_tab.h Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
test_sjis.c ECI conversion for GRIDMATRIX; GB 2312 LIBICONV port 2019-11-28 19:15:29 +00:00
test_upcean.c EANX/UPCA/UPCE_CHK handling + various raster/vector fixes; ISBNX add-ons 2019-11-11 21:38:21 +00:00
test_vector.c EANX/UPCA/UPCE_CHK handling + various raster/vector fixes; ISBNX add-ons 2019-11-11 21:38:21 +00:00
testcommon.c Handle UNICODE_MODE ECI conversion for reduced charset barcodes and QRCODE/MICROQR 2019-11-27 16:16:14 +00:00
testcommon.h Always parse input as GS1 for EAN128 and RSS_EXP 2019-10-17 10:06:21 +01:00

Zint backend test suite
-----------------------

To make:

  cd <project-dir>
  cd backend/tests
  mkdir build
  cd build
  cmake ..
  make

To run all tests:

  make test

To run individual tests, eg:

  ./test_common
  ./test_vector

To make with gcc sanitize, first set for libzint and make:

  cd <project-dir>
  cd build
  cmake -DZINT_SANITIZE:BOOL=1 ..
  make && sudo make install

Then set for tests and make:

  cd <project-dir>
  cd backend/tests/build
  cmake -DZINT_SANITIZE:BOOL=1 ..
  make

Similarly to make with gcc debug:

  cd <project-dir>
  cd build
  cmake -DZINT_DEBUG:BOOL=1 ..
  make && sudo make install

  cd <project-dir>
  cd backend/tests/build
  cmake -DZINT_DEBUG:BOOL=1 ..
  make

To undo sanitize/debug, remake each after setting:

  cmake -DZINT_SANITIZE:BOOL=0 ..
  cmake -DZINT_DEBUG:BOOL=0 ..

Note that sanitize is not safe to use in production, as it's a security risk.