summaryrefslogtreecommitdiff
path: root/docs/narr/myproject
diff options
context:
space:
mode:
Diffstat (limited to 'docs/narr/myproject')
-rw-r--r--docs/narr/myproject/MANIFEST.in3
-rw-r--r--docs/narr/myproject/pytest.ini7
-rw-r--r--docs/narr/myproject/tests/__init__.py0
-rw-r--r--docs/narr/myproject/tests/test_it.py (renamed from docs/narr/myproject/myproject/tests.py)4
4 files changed, 10 insertions, 4 deletions
diff --git a/docs/narr/myproject/MANIFEST.in b/docs/narr/myproject/MANIFEST.in
index 1c24b8c0c..f516697f5 100644
--- a/docs/narr/myproject/MANIFEST.in
+++ b/docs/narr/myproject/MANIFEST.in
@@ -1,2 +1,5 @@
include *.txt *.ini *.cfg *.rst
recursive-include myproject *.ico *.png *.css *.gif *.jpg *.pt *.txt *.mak *.mako *.js *.html *.xml *.jinja2
+recursive-include tests *
+recursive-exclude * __pycache__
+recursive-exclude * *.py[co]
diff --git a/docs/narr/myproject/pytest.ini b/docs/narr/myproject/pytest.ini
index 332cf0d04..5c8c59068 100644
--- a/docs/narr/myproject/pytest.ini
+++ b/docs/narr/myproject/pytest.ini
@@ -1,3 +1,6 @@
[pytest]
-testpaths = myproject
-python_files = test*.py
+addopts = --strict
+
+testpaths =
+ myproject
+ tests
diff --git a/docs/narr/myproject/tests/__init__.py b/docs/narr/myproject/tests/__init__.py
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/docs/narr/myproject/tests/__init__.py
diff --git a/docs/narr/myproject/myproject/tests.py b/docs/narr/myproject/tests/test_it.py
index 48f0095ad..b300da34d 100644
--- a/docs/narr/myproject/myproject/tests.py
+++ b/docs/narr/myproject/tests/test_it.py
@@ -11,13 +11,13 @@ class ViewTests(unittest.TestCase):
testing.tearDown()
def test_my_view(self):
- from .views.default import my_view
+ from myproject.views.default import my_view
request = testing.DummyRequest()
info = my_view(request)
self.assertEqual(info['project'], 'myproject')
def test_notfound_view(self):
- from .views.notfound import notfound_view
+ from myproject.views.notfound import notfound_view
request = testing.DummyRequest()
info = notfound_view(request)
self.assertEqual(info, {})