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
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
def test_key(self): assert self.key in ConfigRegistry.keys()
def test_len(self): assert len(ConfigRegistry.keys()) == 1, ConfigRegistry.keys()
def test_key(self): assert "bb" in ConfigRegistry.keys() assert "cc" in ConfigRegistry.keys()
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])
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])