Skip to content

Commit 2428315

Browse files
authored
wasm2c: Test STDIN_FILE error output line numbers (#2341)
1 parent bcd03e8 commit 2428315

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

test/harness/wasm2c/stdin_file.txt

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
;;; TOOL: run-spec-wasm2c
2+
;;; ERROR: 1
3+
;;; STDIN_FILE: test/harness/wasm2c/stdin_file.wast
4+
(;; STDERR ;;;
5+
stdin_file.wast:4: assertion failed: w2c_stdin__file__0__wasm_x(&stdin__file__0__wasm_instance, 1u) trapped (Unreachable instruction executed).
6+
;;; STDERR ;;)
7+
(;; STDOUT ;;;
8+
0/1 tests passed.
9+
;;; STDOUT ;;)

test/harness/wasm2c/stdin_file.wast

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
(module
2+
(func (export "x") (param $x i32) (result i32) (unreachable))
3+
)
4+
(assert_return (invoke "x" (i32.const 1))
5+
(i32.const 1))

0 commit comments

Comments
 (0)