diff options
author | Wang Xuerui <idontknw.wang@gmail.com> | 2014-11-01 22:52:09 +0800 |
---|---|---|
committer | Wang Xuerui <idontknw.wang@gmail.com> | 2014-11-01 22:52:09 +0800 |
commit | b47eae572342d3f18f0614f7d878b5387cca4553 (patch) | |
tree | 2cece30f2794deb64ea84c78a499a9967bc1bd74 | |
parent | 86712d21fe7c3abdd7e593973fb35010422f1a41 (diff) | |
download | pyscss-b47eae572342d3f18f0614f7d878b5387cca4553.tar.gz |
Add test cases for modulo expression.
-rw-r--r-- | scss/tests/test_expression.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/scss/tests/test_expression.py b/scss/tests/test_expression.py index d895948..33adfe2 100644 --- a/scss/tests/test_expression.py +++ b/scss/tests/test_expression.py @@ -55,6 +55,11 @@ def test_reference_operations(): assert calc('#{$font-size}/#{$line-height}') == String('12px / 30px') # uses #{}; does no division + # Modulo + assert calc('29 % 12') == Number(5) + assert calc('29px % 12') == Number(5, 'px') + assert calc('29px % 12px') == Number(5, 'px') + # Color operations ns.set_variable('$translucent-red', Color.from_rgb(1, 0, 0, 0.5)) ns.set_variable('$green', Color.from_name('lime')) |