diff options
author | Bruce Wells <brucekwells@gmail.com> | 2020-04-21 18:12:55 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-21 18:12:55 +0300 |
commit | 4d50343330183a498c34a20d20e5981c26602c0c (patch) | |
tree | 35f93e3f47d06ce9a03edea2b05b29f1b9147679 /tests | |
parent | 7198653aef6eab55e1644eea9f16bf0dd0dc2edd (diff) |
Negative expression start (#60)V1.1.4
* Update documentation for PHPFUI/InstaDoc
* Support for negative numbers starting paren enclosed expressions
Diffstat (limited to 'tests')
-rw-r--r-- | tests/MathTest.php | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/MathTest.php b/tests/MathTest.php index cc4cd1a..7cbc7de 100644 --- a/tests/MathTest.php +++ b/tests/MathTest.php @@ -114,6 +114,7 @@ class MathTest extends \PHPUnit\Framework\TestCase ['(5 + 3) * -1'], + ['-2- 2*2'], ['2- 2*2'], ['2-(2*2)'], ['(2- 2)*2'], @@ -155,6 +156,7 @@ class MathTest extends \PHPUnit\Framework\TestCase ['-1*-2'], ['(1+2+3+4-5)*7/100'], + ['(-1+2+3+4- 5)*7/100'], ['(1+2+3+4- 5)*7/100'], ['( 1 + 2 + 3 + 4 - 5 ) * 7 / 100'], @@ -176,6 +178,7 @@ class MathTest extends \PHPUnit\Framework\TestCase ['3 <= 5'], ['5 <= 5'], ['10 < 9 || 4 > (2+1)'], + ['10 < 9 || 4 > (-2+1)'], ['10 < 9 || 4 > (2+1) && 5 == 5 || 4 != 6 || 3 >= 4 || 3 <= 7'], ['1 + 5 == 3 + 1'], @@ -193,7 +196,11 @@ class MathTest extends \PHPUnit\Framework\TestCase ['(-4)'], ['(-4 + 5)'], - + ['(3 * 1)'], + ['(-3 * -1)'], + ['1 + (-3 * -1)'], + ['1 + ( -3 * 1)'], + ['1 + (3 * -1)'], ['1 - 0'], ['1-0'], ]; |