From 290daa15d9111b3ae7390245406ce95bff6598e8 Mon Sep 17 00:00:00 2001 From: Damien George Date: Tue, 27 Sep 2016 15:44:56 +1000 Subject: [PATCH] tests/float: Add test for parsing a float from an empty string. --- tests/float/float1.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/float/float1.py b/tests/float/float1.py index 27fe26205b..f21f5bcdd3 100644 --- a/tests/float/float1.py +++ b/tests/float/float1.py @@ -22,6 +22,10 @@ print(float("infinity")) print(float("INFINITY")) print(float("nan")) print(float("NaN")) +try: + float("") +except ValueError: + print("ValueError") try: float("1e+") except ValueError: