]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
vici: Move Python test dir and include it in sdist
authorTobias Brunner <tobias@strongswan.org>
Tue, 14 Jan 2020 13:58:01 +0000 (14:58 +0100)
committerTobias Brunner <tobias@strongswan.org>
Tue, 14 Jan 2020 15:53:19 +0000 (16:53 +0100)
This is the recommended location and import config as it allows running the
tests against installed versions of the package.  And while the test file
itself is automatically included in the source distribution this way, the
__init__.py file is not, so we still have to update MANIFEST.in.

src/libcharon/plugins/vici/python/MANIFEST.in
src/libcharon/plugins/vici/python/Makefile.am
src/libcharon/plugins/vici/python/test/__init__.py [moved from src/libcharon/plugins/vici/python/vici/test/__init__.py with 100% similarity]
src/libcharon/plugins/vici/python/test/test_protocol.py [moved from src/libcharon/plugins/vici/python/vici/test/test_protocol.py with 98% similarity]

index 9d5d250d095009403f66851f48866f5cfe39703b..883ea5d521dd7162435b0d0df8bb7f32c853ab5f 100644 (file)
@@ -1,2 +1,4 @@
 include LICENSE
 include README.rst
+include tox.ini
+recursive-include test *.py
index 8a9e6fc263861bf397b868f5a0c9ae02ba3c9f42..a2e7596e48fbaf8a3412a5282a9b39d70332d5cf 100644 (file)
@@ -2,8 +2,8 @@ EXTRA_DIST = LICENSE README.rst MANIFEST.in \
        setup.py.in \
        tox.ini \
        tox.sh \
-       vici/test/__init__.py \
-       vici/test/test_protocol.py \
+       test/__init__.py \
+       test/test_protocol.py \
        vici/__init__.py \
        vici/command_wrappers.py \
        vici/compat.py \
similarity index 98%
rename from src/libcharon/plugins/vici/python/vici/test/test_protocol.py
rename to src/libcharon/plugins/vici/python/test/test_protocol.py
index 7ae1f2f905143c1735f11d5205e078e501d4a3e1..1924884a11d0ca498f10773e9ebf1a2ddb882c8a 100644 (file)
@@ -1,7 +1,7 @@
 import pytest
 
-from ..protocol import Packet, Message, FiniteStream
-from ..exception import DeserializationException
+from vici.protocol import Packet, Message, FiniteStream
+from vici.exception import DeserializationException
 
 
 class TestPacket(object):