Skip to content

Commit d84d17e

Browse files
authored
Merge pull request #2 from fispact/move_tests
Moved tests out of package and fixes to pypi setup.
2 parents d8f3e4b + 4f8a26d commit d84d17e

21 files changed

+61
-38
lines changed

.coveragerc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
[run]
2-
omit = pypact/tests/*
2+
omit = tests/*

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ before_script:
1212
script:
1313
- pip3 install -e $PYPACT
1414
- python $PYPACT/setup.py test
15-
- coverage run $PYPACT/pypact/tests/testsuite.py
15+
- coverage run $PYPACT/tests/testsuite.py
1616
- pylint -j4 $PYPACT/pypact --rcfile=$PYPACT/.pylintrc || true
1717
- fispactconverter.py $PYPACT/reference/test31.out test31.json
1818
# - diff test31.json $PYPACT/reference/test31.json

pypact/tests/testsuite.py

Lines changed: 0 additions & 18 deletions
This file was deleted.

pytest.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[pytest]
22
addopts = --cov-config .coveragerc --cov=./pypact
3-
python_files = pypact/tests/testsuite.py
3+
python_files = tests/testsuite.py

setup.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,24 @@
22

33

44
setup(name='pypact',
5-
version='1.1.0',
5+
version='1.1.1',
66
description='The package for reading and manipulating the fispact output text file.',
77
url='https://github.com/fispact/pypact',
88
author='UKAEA',
99
author_email='[email protected]',
1010
license='Apache License 2.0',
1111
packages=[
12-
'pypact'
12+
'pypact',
13+
'pypact.analysis',
14+
'pypact.library',
15+
'pypact.output',
16+
'pypact.tools',
17+
'pypact.util'
1318
],
1419
install_requires=[],
1520
python_requires='>=3',
1621
scripts=['pypact/tools/fispactconverter.py'],
1722
setup_requires=['pytest-runner'],
18-
test_suite='pypact.tests.testsuite',
23+
test_suite='tests.testsuite',
1924
tests_require=['pytest'],
2025
zip_safe=False)
File renamed without changes.
File renamed without changes.

pypact/tests/output/baseoutputtest.py renamed to tests/output/baseoutputtest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import os
22
from pypact.filerecord import FileRecord
3-
from pypact.tests.testerbase import Tester, REFERENCE_DIR
3+
from tests.testerbase import Tester, REFERENCE_DIR
44

55

66
class BaseOutputUnitTest(Tester):

pypact/tests/output/doseratetest.py renamed to tests/output/doseratetest.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
import math
2+
3+
from tests.output.baseoutputtest import BaseOutputUnitTest
4+
25
from pypact.util.numerical import nan
36
from pypact.filerecord import FileRecord
4-
from pypact.tests.output.baseoutputtest import BaseOutputUnitTest
57
from pypact.output.doserate import DoseRate
68

79

pypact/tests/output/nuclidestest.py renamed to tests/output/nuclidestest.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
from pypact.tests.output.baseoutputtest import BaseOutputUnitTest
1+
from tests.output.baseoutputtest import BaseOutputUnitTest
2+
23
from pypact.output.nuclides import Nuclides
34
from pypact.output.nuclide import Nuclide
45

0 commit comments

Comments
 (0)