mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 10:12:06 +00:00
Improve RGBASM test coverage
This commit is contained in:
@@ -32,3 +32,4 @@ char '?', $3f ; ASCII
|
||||
char 'F', 0
|
||||
char 'ABF', 0
|
||||
char '\n\r\t', 0
|
||||
assert 0 == '
|
||||
|
||||
@@ -12,4 +12,8 @@ warning: character-literals.asm(34) -> character-literals.asm::char(13): [-Wunma
|
||||
Unmapped character '\t'
|
||||
error: character-literals.asm(34) -> character-literals.asm::char(13):
|
||||
Character literals must be a single charmap unit
|
||||
Assembly aborted with 3 errors!
|
||||
error: character-literals.asm(35):
|
||||
Unterminated character
|
||||
error: character-literals.asm(35):
|
||||
Character literals must be a single charmap unit
|
||||
Assembly aborted with 5 errors!
|
||||
|
||||
1
test/asm/include-slash.asm
Normal file
1
test/asm/include-slash.asm
Normal file
@@ -0,0 +1 @@
|
||||
println x
|
||||
3
test/asm/include-slash.err
Normal file
3
test/asm/include-slash.err
Normal file
@@ -0,0 +1,3 @@
|
||||
error: include-slash.asm(0):
|
||||
Error reading pre-included file 'include-slash-nonexist.inc': No such file or directory
|
||||
Assembly aborted with 1 error!
|
||||
1
test/asm/include-slash.flags
Normal file
1
test/asm/include-slash.flags
Normal file
@@ -0,0 +1 @@
|
||||
-Weverything -P include-slash.inc -I include -P include-slash-nonexist.inc
|
||||
1
test/asm/include-slash.out
Normal file
1
test/asm/include-slash.out
Normal file
@@ -0,0 +1 @@
|
||||
$2A
|
||||
1
test/asm/include/include-slash.inc
Normal file
1
test/asm/include/include-slash.inc
Normal file
@@ -0,0 +1 @@
|
||||
def x = 42
|
||||
@@ -12,7 +12,7 @@ def variable += 1
|
||||
|
||||
def con2 equ -1
|
||||
def var2 = variable**2
|
||||
def str2 equs strcat("{string}", "\0\n\t\r")
|
||||
def str2 equs strcat("{string}", "\0\n\t\r\\\"\{")
|
||||
charmap "c2", 10, -11, 987654321
|
||||
|
||||
PURGE polo
|
||||
|
||||
@@ -10,7 +10,7 @@ def var2 = $9
|
||||
|
||||
; String constants
|
||||
def string equs "goodbye~"
|
||||
def str2 equs "hello!\0\n\t\r"
|
||||
def str2 equs "hello!\0\n\t\r\\\"\{"
|
||||
|
||||
; Character maps
|
||||
newcharmap main
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
fname=$(mktemp)
|
||||
|
||||
for i in *.asm; do
|
||||
../../rgbasm $i >$fname 2>&1
|
||||
mv -f $fname ${i%.asm}.out
|
||||
done
|
||||
|
||||
rm -f $fname
|
||||
exit 0
|
||||
Reference in New Issue
Block a user