unit test : write a blacklisted module

This commit is contained in:
alalazo 2016-06-04 16:23:41 +02:00
parent 408aa10210
commit 09b1daa7b9

View file

@ -211,6 +211,9 @@ def test_blacklist(self):
print('\n'.join(content)) print('\n'.join(content))
self.assertEqual(len([x for x in content if 'is-loaded' in x]), 1) self.assertEqual(len([x for x in content if 'is-loaded' in x]), 1)
self.assertEqual(len([x for x in content if 'module load ' in x]), 1) self.assertEqual(len([x for x in content if 'module load ' in x]), 1)
spec = spack.spec.Spec('callpath arch=x86-linux')
# Returns a StringIO instead of a string as no module file was written
self.assertRaises(AttributeError, self.get_modulefile_content, spec)
def test_conflicts(self): def test_conflicts(self):
spack.modules.CONFIGURATION = configuration_conflicts spack.modules.CONFIGURATION = configuration_conflicts