#!/bin/sh
# Copyright 2018 by Denys Vlasenko
# Licensed under GPLv2 or later, see file LICENSE in this source tree.

. ./testing.sh

# testing "test name" "command" "expected result" "file input" "stdin"

testing "bc comment 1" \
	"bc" \
	"3\n" \
	"" "1 /* comment */ + 2"

testing "bc comment 2: /*/ is not a closed comment" \
	"bc" \
	"4\n" \
	"" "1 /*/ + 2 */ + 3"

testing "bc comment 3: unterminated #comment" \
	"bc" \
	"" \
	"" "#foo"  # no trailing newline

testing "bc backslash 1" \
	"bc" \
	"3\n" \
	"" "1 \\\\\n + 2"

testing "bc string 1" \
	"bc" \
	"STR\n" \
	"" "\"STR\n\""

testing "bc if 0 else" \
	"bc" \
	"2\n9\n" \
	"" "if (0) 1 else 2; 9"

testing "bc if 1 else" \
	"bc" \
	"1\n9\n" \
	"" "if (1) 1 else 2; 9"

testing "bc if 1 if 1 else else" \
	"bc" \
	"1\n9\n" \
	"" "if (1) if (1) 1 else 2 else 3; 9"

testing "bc if 0 else if 1" \
	"bc" \
	"2\n9\n" \
	"" "if (0) 1 else if (1) 2; 9"

testing "bc for(;;)" \
	"bc" \
	"2\n3\n2\n9\n" \
	"" "i=2; for (;;) { 2; if(--i==0) break; 3; }; 9"

testing "bc for (;cond;)" \
	"bc" \
	"1\n2\n3\n9\n" \
	"" "i=0; for(;i<3;)++i; 9"

testing "bc for (;cond;upd)" \
	"bc" \
	"1\n2\n3\n9\n" \
	"" "i=1; for(;i<4;i++)i; 9"

testing "bc for (init;cond;upd)" \
	"bc" \
	"1\n2\n3\n9\n" \
	"" "for(i=1;i<4;i++)i; 9"

testing "bc define auto" \
	"bc" \
	"8\n9\n" \
	"" "define w() { auto z; return 8; }; w(); 9"

testing "bc define with body on next line" \
	"bc" \
	"8\n9\n" \
	"" "define w()\n{ auto z; return 8; }\nw()\n9"

testing "bc if(cond)<NL>" \
	"bc" \
	"9\n" \
	"" "if(0)\n3\n9"

testing "bc if(cond) stmt else<NL>" \
	"bc" \
	"4\n9\n" \
	"" "if(0)3 else\n4\n9"

testing "bc while(cond)<NL>" \
	"bc" \
	"8\n7\n6\n5\n4\n3\n2\n1\n9\n" \
	"" "i=9;while(--i)\ni\n9"

testing "bc ifz does not match if keyword" \
	"bc" \
	"1\n2\n2\n3\n" \
	"" "ifz=1;ifz\n++ifz;ifz++\nifz"

testing "bc print 1,2,3" \
	"bc" \
	"123" \
	"" "print 1,2,3"

testing "bc { print 1 }" \
	"bc" \
	"1" \
	"" "{ print 1 }"

testing "bc nested loops and breaks" \
	"bc" \
	"\
11
21
31
22
12
99
" \
	"" "\
if(1) {
	11
	while(1) {
		21
		while(1) {
			31
			break
			32
		}
		22
		break
		23
	}
	12
} else {
	88
}
99
"

testing "bc continue in if" \
	"bc" \
	"\
11
21
11
31
99
" \
	"" "\
i=2
while(i--) {
        11
        if(i) {
                21
                continue
                22
        } else {
                31
                continue
                32
	}
        12
}
99
"

testing "bc continue in for" \
	"bc" \
	"\
1
77
2
99
" \
	"" "\
for(i=1; i<3; i++) {
    i
    if(i==2) continue
    77
}
99
"

tar xJf bc_large.tar.xz

for f in bc*.bc; do
	r="`basename "$f" .bc`_results.txt"
	test -f "$r" || continue
	# testing "test name" "command" "expected result" "file input" "stdin"
	testing "bc -lq $f" \
		"{ { bc -lq $f 2>&1; echo E:\$? >&2; } | diff -u - $r; echo E:\$?; } 2>&1" \
		"E:0\nE:0\n" \
		"" ""
done

exit $FAILCOUNT
