Rangi42
0670c03bc2
Add CLI tests for RGBASM
2025-09-25 11:57:56 -04:00
Rangi42
1fdeb34e50
Fix too-short .out.bin expected test results
...
RGBASM tests now use `rgblink -x` instead of `dd` to get trimmed
test output. RGBLINK tests cannot do so because some of them
(e.g. bank-numbers.asm and sizeof-startof.asm) rely on ROMX
sections above 1, and `-x` implies `-t` which breaks that.
2025-09-15 09:25:33 -04:00
Rangi
5f8b7474b4
Add -B/--backtrace option to RGBASM and RGBLINK ( #1787 )
2025-08-11 14:30:14 -04:00
Rangi42
7ade3e74b3
Avoid the need to repeat -Weverything in test .flags
2025-08-11 08:11:32 -04:00
Rangi
510a4aa99d
Add RGBASM -MC flag to continue -MG after missing dependency files ( #1687 )
2025-07-10 13:25:36 -04:00
Rangi
03452c6d4f
Allow git describe to get the version for FreeBSD and Cygwin in CI ( #1640 )
...
* Specify `safe.directory`
* Fetch tags
* Fetch all commits
2025-01-29 19:57:15 -05:00
Rangi
a59867cd78
Consistently use LF line endings in expected .out and .err output ( #1635 )
...
Test scripts compare files as text
2025-01-28 21:24:40 -05:00
Rangi42
8cd0e66297
Revert "Implement INCLUDE_ONCE directive ( #1481 )"
...
This reverts commit 5f07095f6d .
2024-09-08 11:30:31 -04:00
sukus
5f07095f6d
Implement INCLUDE_ONCE directive ( #1481 )
...
Identify files by (device, inode), not by path, so that symlinks,
relative paths, case-insensitive paths, or other edge cases
do not result in double includes.
2024-09-08 00:02:02 -04:00
ISSOtm
610f04beeb
Fix condition for assuming at EOF
...
Part of that condition's purpose is to ensure that we read the correct
lexer state; but it's possible now for the fstack to be non-empty
*before* the lexer state is registered, i.e. if there is an error
in the function that registers it.
This causes a NULL pointer deref.
2024-09-05 17:48:52 +02:00
ISSOtm
e289387b09
Avoid attempting to link if assembling fails
2024-09-05 17:19:05 +02:00
Rangi42
c07371c9fc
Revert "Show test issues as annotations in the GitHub Actions job summary"
...
This reverts commit 3a5ff35928 .
Annotations were not actually appearing.
<https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/workflow-commands-for-github-actions >
2024-08-27 14:07:35 -04:00
Rangi42
3a5ff35928
Show test issues as annotations in the GitHub Actions job summary
2024-08-27 01:02:53 -04:00
ISSOtm
4ce6c9f4a5
Avoid bogus comparisons when linking fails
...
This avoids drowning RGBLINK's errors in a meaningless `diff` output
2024-08-26 22:58:38 -04:00
Sylvie
8c96293b11
Test the RGBASM state file output ( #1472 )
2024-08-19 20:13:27 +02:00
Rangi42
731715ff36
Refactor test.sh scripts for consistency
2024-08-18 21:38:45 -04:00
Sylvie
96c808810f
Remove .simple.err files, since we require Bison 3.0 ( #1373 )
2024-03-22 15:36:32 -04:00
Rangi42
e701faa1bc
Print summaries at the end of test.sh scripts
2024-03-07 16:45:53 -05:00
Rangi
39018174c5
Scramble banks from the end of the ROM ( #1273 )
...
This is more likely to test edge cases, such as having content in banks with their highest bit set.
2023-12-17 20:14:03 -05:00
Rangi42
b46aa0f55b
colour->color, behaviour->behavior
...
These spellings are more common elsewhere in the codebase
2023-11-27 16:02:17 -05:00
Rangi
92836408cc
Remove empty .out and .err test files ( #1249 )
...
Co-authored-by: ISSOtm <me@eldred.fr >
2023-11-24 17:52:55 -05:00
ISSOtm
6f0defbfe5
Fix shellcheck warnings in the test scripts
...
Making them more robust to changes.
We ought to automate this some day.
My version of ShellCheck (v0.9.0) errors on test/gfx/test.sh, though...
2023-11-24 20:54:28 +01:00
Rangi
a47da5f71f
Deprecate __FILE__ and __LINE__ ( #1072 )
...
Unlike C, these constants are not convenient for logging in macros,
since they always report the same data (their location in the macro).
Fixes #1068
2022-09-30 19:48:30 +02:00
Rangi
b8385a50e3
Support -P/--preinclude to pre-INCLUDE a file ( #1043 )
...
Fixes #1041
Co-authored-by: ISSOtm <eldredhabert0@gmail.com >
2022-09-24 12:37:16 -04:00
DaKnig
34bc650341
Fix shebangs ( #992 )
2022-07-01 22:59:41 +02:00
Rangi
9923fa3eee
Fix expansions that start from the end of another expansion ( #839 )
...
Do not free an expansion until its offset is *past* its size.
This means potentially freeing a nested stack of expansions
all at once.
Fixes #696
2021-04-17 13:14:40 -04:00
Rangi
bcb78f5d18
Define __RGBDS_VERSION__ as the output of rgbasm --version (sans "rgbasm")
...
Fixes #824
2021-04-09 19:42:48 +02:00
ISSOtm
028e7af7d1
Prepare release candidates
...
We'll use "-rcX" instead of "-pre" to allow multiple ones, jic
Additionally, they will be able to be detected using __RGBDS_RC__
Finally, adapt everything version-related to this new system
2021-03-10 00:06:32 +01:00
ISSOtm
611bd46e0b
Ignore CRLF vs LF for syntax error test check
2021-03-09 22:58:32 +01:00
ISSOtm
e67254093e
Delete version test if stale
2021-03-09 22:58:00 +01:00
Rangi
e7d6ddf593
Fix linking tiny overlay files ( #755 )
...
* Fix compatibility of rgblink -O and -t
The -t "tiny mode" option makes ROM0 cover 0x8000 bytes,
not 0x4000. The -O "overlay" option fills areas uncovered
by sections with data from an overlay file. These needed
to cooperate so that the calculated uncovered overlay size
does not exceed the actual size of the ROM.
Fixes #754
* Print link test names like asm tests do
* Make the three test.sh scripts more similar
2021-02-24 23:04:51 -05:00
Rangi
eb4952c188
Use more verbose syntax error messages
...
Fixes #385
2021-01-14 18:36:10 +01:00
Rangi
a70ecba06f
Implement PRINT and PRINTLN ( #672 )
...
Fixes #669
Closes #368
Closes #624
Deprecate PRINTT, PRINTV, PRINTI, and PRINTF
Default STRFMT("%f") to 5 fractional digits like "{f:}"
Any use of string formatting will share this default
2021-01-02 02:37:32 +01:00
ISSOtm
7bc42d468b
Clean up temp test files even if interrupted
...
Avoids "tmp.*" piling up in /tmp
2020-12-26 14:38:04 +01:00
ISSOtm
bdfce25db0
Avoid running version test when git describe fails
...
Can happen when not enough history has been fetched, notably in our CI
2020-12-10 13:43:22 +01:00
ISSOtm
bf789dd7b3
Add automated test for version consistency
...
Automatically check that the version number constants
(__RGBDS_MAJOR__ etc.) match `rgbasm -V`
Should avoid the problem with 0.4.2's release...
2020-12-10 12:22:29 +01:00
ISSOtm
cd747d8175
Fix many lexer bugs
...
More to come...
2020-10-04 04:39:25 +02:00
ISSOtm
c0808246e5
Silence the mingw test
...
Use "quiet" instead of "count"...
2020-09-27 10:51:52 +02:00
ISSOtm
9742fa731c
Run the quote in file name except on Windows
...
This should make the CI function again
2020-09-22 18:13:26 +02:00
ISSOtm
6563133426
Avoid using echo -e in tests
2020-07-27 18:26:05 +02:00
ISSOtm
e233c5d256
Don't drop RGBLINK output in RGBASM tests
2020-03-22 10:43:06 +01:00
ISSOtm
579a324ce7
Fix diffing bin files in RGBASM tests
2020-02-09 13:58:47 +01:00
ISSOtm
ee34200e5f
Output diffs when binary tests fail
2020-02-06 15:36:15 +01:00
ISSOtm
44cdcd12c3
Use tput for formatting escape sequences
2020-01-28 21:04:41 +01:00
ISSOtm
cdf6000618
Report failing file names in comparisons
...
The files being diffed (especially for variants) are temp files, so their
names are pretty nondescript. This improve error output, using ANSI escape
sequences to make those lines stand out.
2020-01-28 11:44:50 +01:00
ISSOtm
1bd41bf79a
Don't use diff to compare bin files in tests
2020-01-26 21:10:31 +01:00
ISSOtm
56d5f1588a
Do not run .pipe tests if the normal variant fails
...
They'll most likely fail as well, just adding redundant error output
2020-01-21 00:27:28 +01:00
ISSOtm
8a90d74340
Ignore line endings in test suite
...
This removes many false positives with Windows
2020-01-09 01:10:51 +01:00
ISSOtm
5a06fad31e
Separate stdout and stderr in tests
...
POSIX leaves undefined the order of output if stderr is injected into stdout,
and in practice it differs on Windows (Linux buffers both streams separately,
Windows interleaves them as they arrive without buffering).
This should help testing on other platforms
2020-01-09 01:10:51 +01:00
ISSOtm
191ee4ba1f
Add support for toggleable warnings
2019-11-18 20:45:21 +01:00