From 1e8ca3a3cf442733f9210be4d5f6a5b63135a16d Mon Sep 17 00:00:00 2001 From: Sebastian Plamauer Date: Tue, 14 Jul 2015 14:44:31 +0200 Subject: modbuiltins: Implement round() to precision. --- tests/float/builtin_float_round.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tests/float') diff --git a/tests/float/builtin_float_round.py b/tests/float/builtin_float_round.py index 6759d0fd5..4419b744b 100644 --- a/tests/float/builtin_float_round.py +++ b/tests/float/builtin_float_round.py @@ -2,10 +2,11 @@ # check basic cases tests = [ - 0.0, 1.0, 0.1, -0.1, 123.4, 123.6, -123.4, -123.6 + [0.0], [1.0], [0.1], [-0.1], [123.4], [123.6], [-123.4], [-123.6], + [1.234567, 5], [1.23456, 1], [1.23456, 0], [1234.56, -2] ] for t in tests: - print(round(t)) + print(round(*t)) # check .5 cases for i in range(11): -- cgit v1.2.3