Skip to content
Snippets Groups Projects
Commit 2bc664fe authored by Johannes Schumann's avatar Johannes Schumann
Browse files

yapf

parent 9845bb6d
No related branches found
No related tags found
No related merge requests found
Pipeline #31028 passed
......@@ -109,6 +109,7 @@ HE_PARAMS = {
def _get_particle_rest_mass(pdgid):
@np.vectorize
def vfunc(x):
try:
......
......@@ -28,6 +28,7 @@ MUON_TESTFILE = join(dirname(__file__), "data/muon_range_seawater.txt")
class TestKineticEnergy(unittest.TestCase):
def test_electron_mass(self):
val = get_kinetic_energy(0.51099895e-3, 11)[0]
self.assertAlmostEqual(val, 0.0, 6)
......@@ -44,8 +45,8 @@ class TestKineticEnergy(unittest.TestCase):
assert len(w) == 0
class TestMuonRangeSeaWater(unittest.TestCase):
def setUp(self):
self.ref_values = np.loadtxt(MUON_TESTFILE).T
......@@ -57,6 +58,7 @@ class TestMuonRangeSeaWater(unittest.TestCase):
class TestVisEnergyParticle(unittest.TestCase):
def setUp(self):
with open(PARTICLE_TESTFILE, "r") as f:
tmp = f.readline()
......@@ -75,6 +77,7 @@ class TestVisEnergyParticle(unittest.TestCase):
class TestVisEnergyWeightFunctions(unittest.TestCase):
def setUp(self):
self.ref_values = np.loadtxt(FUNCTIONS_TESTFILE).T
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment