diff --git a/.testr.conf b/.testr.conf index 888f7de0d6..ad0695f865 100644 --- a/.testr.conf +++ b/.testr.conf @@ -2,7 +2,7 @@ test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \ OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \ OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-60} \ - ${PYTHON:-python} -m subunit.run discover -t ./ ./ $LISTOPT $IDOPTION + ${PYTHON:-python} -m subunit.run discover -t ./ openstack_requirements/ $LISTOPT $IDOPTION test_id_option=--load-list $IDFILE test_list_option=--list diff --git a/tests/__init__.py b/openstack_requirements/__init__.py similarity index 100% rename from tests/__init__.py rename to openstack_requirements/__init__.py diff --git a/openstack_requirements/tests/__init__.py b/openstack_requirements/tests/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/tests/common.py b/openstack_requirements/tests/common.py similarity index 71% rename from tests/common.py rename to openstack_requirements/tests/common.py index 1ab8687f6f..4ee5d02229 100644 --- a/tests/common.py +++ b/openstack_requirements/tests/common.py @@ -49,18 +49,23 @@ class Project(fixtures.Fixture): project_fixture = Project( - "tests/files/project.txt", - "tests/files/setup.py", "tests/files/setup.cfg", - "tests/files/test-project.txt") + "openstack_requirements/tests/files/project.txt", + "openstack_requirements/tests/files/setup.py", + "openstack_requirements/tests/files/setup.cfg", + "openstack_requirements/tests/files/test-project.txt") bad_project_fixture = Project( - "tests/files/project-with-bad-requirement.txt", "tests/files/setup.py", - "tests/files/setup.cfg") + "openstack_requirements/tests/files/project-with-bad-requirement.txt", + "openstack_requirements/tests/files/setup.py", + "openstack_requirements/tests/files/setup.cfg") oslo_fixture = Project( - "tests/files/project-with-oslo-tar.txt", "tests/files/old-setup.py", - "tests/files/setup.cfg") + "openstack_requirements/tests/files/project-with-oslo-tar.txt", + "openstack_requirements/tests/files/old-setup.py", + "openstack_requirements/tests/files/setup.cfg") pbr_fixture = Project( - "tests/files/project.txt", "tests/files/setup.py", - "tests/files/pbr_setup.cfg", "tests/files/test-project.txt") + "openstack_requirements/tests/files/project.txt", + "openstack_requirements/tests/files/setup.py", + "openstack_requirements/tests/files/pbr_setup.cfg", + "openstack_requirements/tests/files/test-project.txt") class GlobalRequirements(fixtures.Fixture): @@ -69,4 +74,5 @@ class GlobalRequirements(fixtures.Fixture): super(GlobalRequirements, self).setUp() self.root = self.useFixture(fixtures.TempDir()).path self.req_file = os.path.join(self.root, "global-requirements.txt") - shutil.copy("tests/files/gr-base.txt", self.req_file) + shutil.copy( + "openstack_requirements/tests/files/gr-base.txt", self.req_file) diff --git a/tests/files/gr-base.txt b/openstack_requirements/tests/files/gr-base.txt similarity index 100% rename from tests/files/gr-base.txt rename to openstack_requirements/tests/files/gr-base.txt diff --git a/tests/files/old-setup.py b/openstack_requirements/tests/files/old-setup.py similarity index 100% rename from tests/files/old-setup.py rename to openstack_requirements/tests/files/old-setup.py diff --git a/tests/files/pbr_setup.cfg b/openstack_requirements/tests/files/pbr_setup.cfg similarity index 100% rename from tests/files/pbr_setup.cfg rename to openstack_requirements/tests/files/pbr_setup.cfg diff --git a/tests/files/project-with-bad-requirement.txt b/openstack_requirements/tests/files/project-with-bad-requirement.txt similarity index 100% rename from tests/files/project-with-bad-requirement.txt rename to openstack_requirements/tests/files/project-with-bad-requirement.txt diff --git a/tests/files/project-with-oslo-tar.txt b/openstack_requirements/tests/files/project-with-oslo-tar.txt similarity index 100% rename from tests/files/project-with-oslo-tar.txt rename to openstack_requirements/tests/files/project-with-oslo-tar.txt diff --git a/tests/files/project.txt b/openstack_requirements/tests/files/project.txt similarity index 100% rename from tests/files/project.txt rename to openstack_requirements/tests/files/project.txt diff --git a/tests/files/setup.cfg b/openstack_requirements/tests/files/setup.cfg similarity index 100% rename from tests/files/setup.cfg rename to openstack_requirements/tests/files/setup.cfg diff --git a/tests/files/setup.py b/openstack_requirements/tests/files/setup.py similarity index 100% rename from tests/files/setup.py rename to openstack_requirements/tests/files/setup.py diff --git a/tests/files/test-project.txt b/openstack_requirements/tests/files/test-project.txt similarity index 100% rename from tests/files/test-project.txt rename to openstack_requirements/tests/files/test-project.txt diff --git a/tests/test_update.py b/openstack_requirements/tests/test_update.py similarity index 99% rename from tests/test_update.py rename to openstack_requirements/tests/test_update.py index 0fb84bb436..56e3b18d54 100644 --- a/tests/test_update.py +++ b/openstack_requirements/tests/test_update.py @@ -19,7 +19,7 @@ import StringIO import fixtures import testtools -from tests import common +from openstack_requirements.tests import common import update diff --git a/tests/test_update_pbr.py b/openstack_requirements/tests/test_update_pbr.py similarity index 97% rename from tests/test_update_pbr.py rename to openstack_requirements/tests/test_update_pbr.py index d0b7ee40ac..0a2b6ff7a8 100644 --- a/tests/test_update_pbr.py +++ b/openstack_requirements/tests/test_update_pbr.py @@ -20,7 +20,7 @@ from __future__ import print_function import testtools -from tests import common +from openstack_requirements.tests import common import update diff --git a/tests/test_update_suffix.py b/openstack_requirements/tests/test_update_suffix.py similarity index 98% rename from tests/test_update_suffix.py rename to openstack_requirements/tests/test_update_suffix.py index 0fe6fc1944..9ff5bb6eea 100644 --- a/tests/test_update_suffix.py +++ b/openstack_requirements/tests/test_update_suffix.py @@ -16,7 +16,7 @@ from __future__ import print_function import testtools -from tests import common +from openstack_requirements.tests import common import update