1
0
mirror of https://github.com/cc65/cc65.git synced 2024-09-12 13:54:43 +00:00
cc65/test/asm/listing
Spiro Trikaliotis d7a804d120 Split stdin and stdout in test/asm/
Some tests pipe the stdout and stderr of the compiler or assembler into
a file and compare the result with a reference. This has the subtle
problem that both stdout and stderr and buffered i/o streams that may or
may not work the same on different OSs or even shells. That means the
order of the lines in the resulting file is not guaranteed.

In practise it is "mostly" not an issue, but "we" still stumbled about
one test where different behaviour can be triggered depending on running
it in cmd.exe or bash (msys): test/asm/listing output of
010-paramcount.bin differs from the reference output when running the
test from cmd.exe.

The solution is most likely to have two reference files and not redirect
into one file.

This patch fixes the issue (cf. #1912) for the directory test/asm/.
2022-11-12 23:12:25 +01:00
..
control Testcases for case 2022-06-20 23:03:12 +02:00
ref Split stdin and stdout in test/asm/ 2022-11-12 23:12:25 +01:00
001-macro-simple-listing.s Some test cases for ca65 2022-06-16 20:57:53 +02:00
002-macro-param-listing.s
010-paramcount.s
020-asciiz.s
030-assert-success.s
031-assert-error.s
032-assert-error2.s
032-assert-error3.s More .assert testcases 2022-06-20 16:33:25 +02:00
032-assert-error4.s More .assert testcases 2022-06-20 16:33:25 +02:00
032-assert-error5.s More .assert testcases 2022-06-20 16:33:25 +02:00
032-assert-error6.s More .assert testcases 2022-06-20 16:33:25 +02:00
032-assert-error7.s More .assert testcases 2022-06-20 16:33:25 +02:00
032-assert-error8.s More .assert testcases 2022-06-20 16:33:25 +02:00
033-assert-ldwarning-success.s More assert tests 2022-06-20 22:16:55 +02:00
034-assert-lderror1.s More assert tests 2022-06-20 22:16:55 +02:00
034-assert-lderror2.s More assert tests 2022-06-20 22:16:55 +02:00
034-assert-lderror3.s More assert tests 2022-06-20 22:16:55 +02:00
034-assert-lderror4.s More assert tests 2022-06-20 22:16:55 +02:00
034-assert-lderror5.s More assert tests 2022-06-20 22:16:55 +02:00
034-assert-lderror6.s More assert tests 2022-06-20 22:16:55 +02:00
034-assert-lderror7.s More assert tests 2022-06-20 22:16:55 +02:00
034-assert-lderror8.s More assert tests 2022-06-20 22:16:55 +02:00
040-align.s Remove TABs again 2022-06-20 22:53:46 +02:00
050-case-off-2.s Testcases for case 2022-06-20 23:03:12 +02:00
050-case-off-3.s Testcases for case 2022-06-20 23:03:12 +02:00
050-case-off-4.s Testcases for case 2022-06-20 23:03:12 +02:00
050-case-on-1.s Testcases for case 2022-06-20 23:03:12 +02:00
050-case-on-2.s Testcases for case 2022-06-20 23:03:12 +02:00
050-case-on-3.s Testcases for case 2022-06-20 23:03:12 +02:00
050-case-on-4.s Testcases for case 2022-06-20 23:03:12 +02:00
050-case-on-5.s Testcases for case 2022-06-20 23:03:12 +02:00
100-byte.s
101-byt.s
102-word.s
103-dbyt.s
104-dword.s
105-faraddr.s
106-hibytes.s
107-lobytes.s
Makefile Split stdin and stdout in test/asm/ 2022-11-12 23:12:25 +01:00
readme.txt

Overall test:
-------------

These testcases can be used to test different aspects of the assembler.
The name of a test is everything in the form <test>.s.

The following reference files can be added:

- <test>.bin-ref:
  This is a reference for the resulting binary.
  The binary as binary tested against this file.
  If they are not equal, the test fails.

- <test>.list-ref
  This is a reference for the resulting listing output
  This file *must* have the first line of the listing removed, as that
  contains a ca65 version string, and almost always this will be changed!


Note that the resulting .bin file is generated twice: Once with no listing
file, and once with listing file. This way, one can find out if the listing
file generation changes anything with the resulting binary output.


TODO:
- add the possibility to test for specific error output that are to be
  expected