Example #1
0
 def test_true(self):
     c = ConfigRegistry.loadpys(self.config, MU_SHIELD_ENABLED=True)
     self.assertTrue("muShield" in c)
     assert len(ConfigRegistry.keys()) == 1, ConfigRegistry.keys()
     assert self.key in ConfigRegistry.keys()
     assert ConfigRegistry[self.key].Bfield.max  == 1.5*u.kilogauss
     assert ConfigRegistry[self.key].muShield.dZ1 == 2.5*u.m
Example #2
0
 def test_true(self):
     c = ConfigRegistry.loadpys(self.config, MU_SHIELD_ENABLED=True)
     self.assertIn("muShield", c)
     assert len(ConfigRegistry.keys()) == 1, ConfigRegistry.keys()
     assert self.key in ConfigRegistry.keys()
     assert ConfigRegistry[self.key].Bfield.max == 1.5 * u.kilogauss
     assert ConfigRegistry[self.key].muShield.dZ1 == 2.5 * u.m
Example #3
0
 def test_key(self):
     assert self.key in ConfigRegistry.keys()
Example #4
0
 def test_len(self):
     assert len(ConfigRegistry.keys()) == 1, ConfigRegistry.keys()
Example #5
0
 def test_key(self):
     assert "bb" in ConfigRegistry.keys()
     assert "cc" in ConfigRegistry.keys()
Example #6
0
 def test_false(self):
     ConfigRegistry.loadpys(self.config, MU_SHIELD_ENABLED=False)
     assert len(ConfigRegistry.keys()) == 1, ConfigRegistry.keys()
     assert self.key in ConfigRegistry.keys()
     assert ConfigRegistry[self.key].Bfield.max  == 1.5*u.kilogauss
     self.assertTrue("muShield" not in ConfigRegistry[self.key])
Example #7
0
 def test_key(self):
     assert self.key in ConfigRegistry.keys()
Example #8
0
 def test_len(self):
     assert len(ConfigRegistry.keys()) == 1, ConfigRegistry.keys()
Example #9
0
 def test_key(self):
     assert "bb" in ConfigRegistry.keys()
     assert "cc" in ConfigRegistry.keys()
Example #10
0
 def test_false(self):
     ConfigRegistry.loadpys(self.config, MU_SHIELD_ENABLED=False)
     assert len(ConfigRegistry.keys()) == 1, ConfigRegistry.keys()
     assert self.key in ConfigRegistry.keys()
     assert ConfigRegistry[self.key].Bfield.max == 1.5 * u.kilogauss
     self.assertNotIn("muShield", ConfigRegistry[self.key])