From 1c77f2b360855b7af338b2482879ce0da3e50fa8 Mon Sep 17 00:00:00 2001 From: David Kerkeslager Date: Fri, 4 Aug 2017 19:12:43 -0400 Subject: [PATCH] Added integration test to ensure that order of operations is correct --- examples/05_order_of_operations.fur | 11 +++++++++++ examples/05_order_of_operations.fur.output.txt | 6 ++++++ 2 files changed, 17 insertions(+) create mode 100644 examples/05_order_of_operations.fur create mode 100644 examples/05_order_of_operations.fur.output.txt diff --git a/examples/05_order_of_operations.fur b/examples/05_order_of_operations.fur new file mode 100644 index 0000000..c845db5 --- /dev/null +++ b/examples/05_order_of_operations.fur @@ -0,0 +1,11 @@ +print(1 + 2 * 3) +print('\n') +print(4 + 2 // 3) +print('\n') +print(1 + 2 % 3) +print('\n') +print(1 - 2 * 3) +print('\n') +print(4 - 2 // 3) +print('\n') +print(5 - 2 % 3) diff --git a/examples/05_order_of_operations.fur.output.txt b/examples/05_order_of_operations.fur.output.txt new file mode 100644 index 0000000..d9ae1ce --- /dev/null +++ b/examples/05_order_of_operations.fur.output.txt @@ -0,0 +1,6 @@ +7 +4 +3 +-5 +4 +3 \ No newline at end of file -- 2.20.1