From 68e0d1f30d34f2efc95ed95c11927461852c7956 Mon Sep 17 00:00:00 2001 From: FlyingSamson Date: Sun, 22 May 2022 15:51:03 +0200 Subject: [PATCH] Fix tests for old python versions not supporting type hints --- test/test_document.py | 4 ++-- test/test_svg2paths.py | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/test/test_document.py b/test/test_document.py index f1004bb..6b4a795 100644 --- a/test/test_document.py +++ b/test/test_document.py @@ -22,7 +22,7 @@ class TestDocument(unittest.TestCase): """ Test reading svg object contained in a StringIO object """ with open(join(dirname(__file__), 'polygons.svg'), 'r') as file: # read entire file into string - file_content: str = file.read() + file_content = file.read() # prepare stringio object file_as_stringio = StringIO() # paste file content into it @@ -38,7 +38,7 @@ class TestDocument(unittest.TestCase): """ Test reading svg object contained in a string without svg attributes""" with open(join(dirname(__file__), 'polygons.svg'), 'r') as file: # read entire file into string - file_content: str = file.read() + file_content = file.read() doc = Document.from_svg_string(file_content) diff --git a/test/test_svg2paths.py b/test/test_svg2paths.py index 06220bb..8944586 100644 --- a/test/test_svg2paths.py +++ b/test/test_svg2paths.py @@ -77,7 +77,7 @@ class TestSVG2Paths(unittest.TestCase): """ Test reading svg object contained in a StringIO object """ with open(join(dirname(__file__), 'polygons.svg'), 'r') as file: # read entire file into string - file_content: str = file.read() + file_content = file.read() # prepare stringio object file_as_stringio = StringIO() # paste file content into it @@ -93,7 +93,7 @@ class TestSVG2Paths(unittest.TestCase): """ Test reading svg object contained in a string without svg attributes""" with open(join(dirname(__file__), 'polygons.svg'), 'r') as file: # read entire file into string - file_content: str = file.read() + file_content = file.read() paths, _ = svg_string2paths(file_content) @@ -103,7 +103,7 @@ class TestSVG2Paths(unittest.TestCase): """ Test reading svg object contained in a string with svg attributes""" with open(join(dirname(__file__), 'polygons.svg'), 'r') as file: # read entire file into string - file_content: str = file.read() + file_content = file.read() paths, _, _ = svg_string2paths2(file_content)