diff options
| author | Sky <sky@skychristensen.com> | 2019-10-31 09:24:31 +0100 |
|---|---|---|
| committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2019-10-31 10:07:59 +0100 |
| commit | 459de8dc29a45a40f3c22cb63ebd2b82336f7192 (patch) | |
| tree | 3252827834940c378a09f891ff0cc069fcbdaca6 /tests/template_tests | |
| parent | 17752003a8c115ff79f5f21655f5e9b8b2af67f4 (diff) | |
Added more tests for floatformat filter with negative values.
Diffstat (limited to 'tests/template_tests')
| -rw-r--r-- | tests/template_tests/filter_tests/test_floatformat.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/template_tests/filter_tests/test_floatformat.py b/tests/template_tests/filter_tests/test_floatformat.py index cfc3eaf73b..9cb838854c 100644 --- a/tests/template_tests/filter_tests/test_floatformat.py +++ b/tests/template_tests/filter_tests/test_floatformat.py @@ -26,7 +26,9 @@ class FunctionTests(SimpleTestCase): self.assertEqual(floatformat(7.7), '7.7') self.assertEqual(floatformat(7.0), '7') self.assertEqual(floatformat(0.7), '0.7') + self.assertEqual(floatformat(-0.7), '-0.7') self.assertEqual(floatformat(0.07), '0.1') + self.assertEqual(floatformat(-0.07), '-0.1') self.assertEqual(floatformat(0.007), '0.0') self.assertEqual(floatformat(0.0), '0') self.assertEqual(floatformat(7.7, 0), '8') |
