From: nasm-bot f. C. G. <gor...@gm...> - 2018-11-12 07:01:00
|
Commit-ID: 348e653062b4f5ea89b034e8a9eac1bee929b376 Gitweb: http://repo.or.cz/w/nasm.git?a=commitdiff;h=348e653062b4f5ea89b034e8a9eac1bee929b376 Author: Cyrill Gorcunov <gor...@gm...> AuthorDate: Sun, 4 Nov 2018 23:19:02 +0300 Committer: Cyrill Gorcunov <gor...@gm...> CommitDate: Sun, 11 Nov 2018 21:43:46 +0300 test: nasm-t -- Add fwdoptpp Signed-off-by: Cyrill Gorcunov <gor...@gm...> --- {test => travis/test}/fwdoptpp.asm | 8 ++------ travis/test/fwdoptpp.bin.t | Bin 0 -> 257 bytes travis/test/fwdoptpp.error.stderr | 1 + travis/test/fwdoptpp.fatal.stderr | 1 + travis/test/fwdoptpp.json | 39 ++++++++++++++++++++++++++++++++++++ travis/test/fwdoptpp.warning.bin.t | Bin 0 -> 384 bytes travis/test/fwdoptpp.warning.stderr | 1 + 7 files changed, 44 insertions(+), 6 deletions(-) diff --git a/test/fwdoptpp.asm b/travis/test/fwdoptpp.asm similarity index 87% copy from test/fwdoptpp.asm copy to travis/test/fwdoptpp.asm index e1f5dd6..b885800 100644 --- a/test/fwdoptpp.asm +++ b/travis/test/fwdoptpp.asm @@ -1,7 +1,3 @@ -;Testname=error; Arguments=-fbin -DERROR -ofwdoptpp.bin; Files=stdout stderr fwdoptpp.bin -;Testname=fatal; Arguments=-fbin -DFATAL -ofwdoptpp.bin; Files=stdout stderr fwdoptpp.bin -;Testname=warning; Arguments=-fbin -DWARNING -ofwdoptpp.bin; Files=stdout stderr fwdoptpp.bin - %ifndef ERROR %ifndef FATAL %ifndef WARNING @@ -9,7 +5,7 @@ %endif %endif %endif - + n0: jmp n1 n1: jmp n2 n2: jmp n3 @@ -138,7 +134,7 @@ n124: jmp n125 n125: jmp n126 n126: jmp n127 n127: jmp n0 - + %if ($-$$) > 257 %ifdef FATAL %fatal "Out of space!" diff --git a/travis/test/fwdoptpp.bin.t b/travis/test/fwdoptpp.bin.t new file mode 100644 index 0000000..d9ede46 Binary files /dev/null and b/travis/test/fwdoptpp.bin.t differ diff --git a/travis/test/fwdoptpp.error.stderr b/travis/test/fwdoptpp.error.stderr new file mode 100644 index 0000000..73d6286 --- /dev/null +++ b/travis/test/fwdoptpp.error.stderr @@ -0,0 +1 @@ +./travis/test/fwdoptpp.asm:142: error: Out of space! \ No newline at end of file diff --git a/travis/test/fwdoptpp.fatal.stderr b/travis/test/fwdoptpp.fatal.stderr new file mode 100644 index 0000000..14aef37 --- /dev/null +++ b/travis/test/fwdoptpp.fatal.stderr @@ -0,0 +1 @@ +./travis/test/fwdoptpp.asm:140: fatal: Out of space! \ No newline at end of file diff --git a/travis/test/fwdoptpp.json b/travis/test/fwdoptpp.json new file mode 100644 index 0000000..41d5125 --- /dev/null +++ b/travis/test/fwdoptpp.json @@ -0,0 +1,39 @@ +[ + { + "description": "Test jmp optimization", + "id": "fwdoptpp", + "format": "bin", + "source": "fwdoptpp.asm", + "option": "-Ox", + "target": [ + { "output": "fwdoptpp.bin" } + ] + }, + { + "description": "Test warning directive", + "ref": "fwdoptpp", + "option": "-O0 -DWARNING", + "target": [ + { "output": "fwdoptpp.warning.bin" }, + { "stderr": "fwdoptpp.warning.stderr" } + ] + }, + { + "description": "Test error directive", + "ref": "fwdoptpp", + "option": "-O0 -DERROR -o fwdoptpp.null.bin", + "target": [ + { "stderr": "fwdoptpp.error.stderr" } + ], + "error": "expected" + }, + { + "description": "Test fatal directive", + "ref": "fwdoptpp", + "option": "-O0 -DFATAL -o fwdoptpp.null.bin", + "target": [ + { "stderr": "fwdoptpp.fatal.stderr" } + ], + "error": "expected" + } +] diff --git a/travis/test/fwdoptpp.warning.bin.t b/travis/test/fwdoptpp.warning.bin.t new file mode 100644 index 0000000..808c5a2 Binary files /dev/null and b/travis/test/fwdoptpp.warning.bin.t differ diff --git a/travis/test/fwdoptpp.warning.stderr b/travis/test/fwdoptpp.warning.stderr new file mode 100644 index 0000000..b861e96 --- /dev/null +++ b/travis/test/fwdoptpp.warning.stderr @@ -0,0 +1 @@ +./travis/test/fwdoptpp.asm:144: warning: Out of space! [-w+user] \ No newline at end of file |