From 0c34e2c2d0a164c022b72841e7e925465b53eaab Mon Sep 17 00:00:00 2001 From: ldevillez Date: Thu, 16 Nov 2023 08:44:46 +0100 Subject: [PATCH] Add line test --- CHANGELOG.md | 1 + tests/test_complete_files.py | 5 ++++ tests/testfiles/line.svg | 46 ++++++++++++++++++++++++++++++++++++ tests/testfiles/line.tex | 18 ++++++++++++++ 4 files changed, 70 insertions(+) create mode 100644 tests/testfiles/line.svg create mode 100644 tests/testfiles/line.tex diff --git a/CHANGELOG.md b/CHANGELOG.md index 07dbec3..413f98d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -40,6 +40,7 @@ - Wrapping line now respect newline - Fixing error on treating polylines and polygones - Verbose option to add name of shapes and layers +- Converting line tag ### Security ## v2.1.0 - 2023/06/28 diff --git a/tests/test_complete_files.py b/tests/test_complete_files.py index 5364565..db12ae9 100644 --- a/tests/test_complete_files.py +++ b/tests/test_complete_files.py @@ -37,6 +37,11 @@ def create_test_from_filename(filename, utest, **kwargs): class TestCompleteFiles(unittest.TestCase): """Class test for complete SVG""" + def test_line_shape(self): + """Test complete convert line tag""" + filename = "line" + create_test_from_filename(filename, self, markings="interpret") + def test_linestyle(self): """Test complete convert line with different style""" filename = "lines_style" diff --git a/tests/testfiles/line.svg b/tests/testfiles/line.svg new file mode 100644 index 0000000..bc1a43d --- /dev/null +++ b/tests/testfiles/line.svg @@ -0,0 +1,46 @@ + + + + + + diff --git a/tests/testfiles/line.tex b/tests/testfiles/line.tex new file mode 100644 index 0000000..135f117 --- /dev/null +++ b/tests/testfiles/line.tex @@ -0,0 +1,18 @@ + +\documentclass{article} +\usepackage[utf8]{inputenc} +\usepackage{tikz} + +\begin{document} +\definecolor{cdddddd}{RGB}{221,221,221} + + +\def \globalscale {1.000000} +\begin{tikzpicture}[y=1cm, x=1cm, yscale=\globalscale,xscale=\globalscale, inner sep=0pt, outer sep=0pt] + \path[draw=cdddddd,line width=0.0529cm,miter limit=10.0] (0.0, 12.8058) -- (10.5833, 2.2225); + + + + +\end{tikzpicture} +\end{document}