-
Notifications
You must be signed in to change notification settings - Fork 25
Description
There are two ways to run all tests:
- with ./run_tests -- this one passed
- with csg2csg/test> python3 -m unittest discover -p 'Unit*.py' (or by IDE, ERIC6 for example)
in case 2) there are errors:
======================================================================
FAIL: test_mcnp_material (UnitTestMCNPMaterial.TestMCNPMaterial)
Traceback (most recent call last):
File "/mnt/newdisk1/work/build/csg2csg/csg2csg/test/UnitTestMCNPMaterial.py", line 29, in test_mcnp_material
self.assertEqual(len(matcard.xsid_dictionary),2)
AssertionError: 4 != 2
======================================================================
FAIL: test_mcnp_material_with_duplicates (UnitTestMCNPMaterial.TestMCNPMaterial)
Traceback (most recent call last):
File "/mnt/newdisk1/work/build/csg2csg/csg2csg/test/UnitTestMCNPMaterial.py", line 55, in test_mcnp_material_with_duplicates
self.assertEqual(len(matcard.xsid_dictionary),2)
AssertionError: 4 != 2
======================================================================
FAIL: test_serpent_material (UnitTestSerpentMaterial.TestSerpentMaterial)
Traceback (most recent call last):
File "/mnt/newdisk1/work/build/csg2csg/csg2csg/test/UnitTestSerpentMaterial.py", line 31, in test_serpent_material
self.assertEqual(len(matcard.xsid_dictionary),2)
AssertionError: 4 != 2
Looks like somehow UnitTestMCNPInput change state of system before running UnitTestSerpentMaterial and UnitTestMCNPMaterial.
And it makes tests to fail.