From 444a80012bf6d246842f133a89943ccf1004fd87 Mon Sep 17 00:00:00 2001 From: Patrick Shriwise Date: Tue, 11 Oct 2022 23:38:13 -0500 Subject: [PATCH] Naming tally in activation unit test --- tests/unit_tests/test_deplete_activation.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/unit_tests/test_deplete_activation.py b/tests/unit_tests/test_deplete_activation.py index 1842ad8ac..2dc911c86 100644 --- a/tests/unit_tests/test_deplete_activation.py +++ b/tests/unit_tests/test_deplete_activation.py @@ -33,7 +33,7 @@ def model(): ) model.settings.run_mode = 'fixed source' - rx_tally = openmc.Tally() + rx_tally = openmc.Tally(name='activation tally') rx_tally.scores = ['(n,gamma)'] model.tallies.append(rx_tally) @@ -53,7 +53,8 @@ def test_activation(run_in_tmpdir, model, reaction_rate_mode, reaction_rate_opts # Determine (n.gamma) reaction rate using initial run sp = model.run() with openmc.StatePoint(sp) as sp: - tally = sp.tallies[1] + print(sp.tallies) + tally = sp.get_tally(name='activation tally') capture_rate = tally.mean.flat[0] # Create one-nuclide depletion chain