Fix svg_util_test not working anymore from direct manual execution.

Annoying hack, but cannot think of any better solution for now.
This commit is contained in:
Bastien Montagne 2019-09-19 12:26:50 +02:00
parent 7842e73199
commit 92899421cc
1 changed files with 7 additions and 1 deletions

View File

@ -20,7 +20,13 @@
# <pep8 compliant>
from .svg_util import parse_array_of_floats
# XXX Not really nice, but that hack is needed to allow execution of that test
# from both automated CTest and by directly running the file manually...
if __name__ == '__main__':
from svg_util import parse_array_of_floats
else:
from .svg_util import parse_array_of_floats
import unittest