Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
e5cf31f
add mg speed access, adjust fission emission time
ilhamv Feb 28, 2024
ef0869b
clang-format
ilhamv Feb 28, 2024
508fa13
fix traveled distance at time futoff
ilhamv Feb 28, 2024
ad07c3d
add delayed fission time
ilhamv Feb 28, 2024
c72f753
update docs: sampling delay time
ilhamv Feb 29, 2024
08c883e
add settings:max_secondaries
ilhamv Feb 29, 2024
14f96c9
update default max_secondaries at in finalize.cpp
ilhamv Feb 29, 2024
b548606
Merge branch 'openmc-dev:develop' into transient
ilhamv Mar 8, 2024
e388596
Update docs/source/methods/neutron_physics.rst
ilhamv Mar 11, 2024
8c76b05
Merge branch 'openmc-dev:develop' into transient
ilhamv Mar 11, 2024
5b665eb
Merge branch 'openmc-dev:develop' into transient
ilhamv Mar 13, 2024
f729e6a
add pulsed pincell example
ilhamv Mar 13, 2024
9a922df
Merge branch 'transient' of https://github.com/ilhamv/openmc into tra…
ilhamv Mar 13, 2024
9b17fa5
Merge branch 'openmc-dev:develop' into transient
ilhamv Apr 3, 2024
6ca1ae0
debug mg_mode + collision_estimator + survival_biasing
ilhamv Apr 3, 2024
718356f
Small fixes/updates
paulromano Apr 24, 2024
960ed7d
Merge branch 'develop' into pr/ilhamv/2898
paulromano Apr 24, 2024
6b2a92a
Add max_secondaries on settings unit test
paulromano Apr 24, 2024
74c82c2
Fix C++ formatting on settings.cpp
paulromano Apr 24, 2024
43528c4
replace splitting roulette with combing
ilhamv May 4, 2024
a095863
Merge branch 'openmc-dev:develop' into combing
ilhamv May 24, 2024
aec938d
Merge branch 'openmc-dev:develop' into transient
ilhamv May 24, 2024
fb88089
Merge branch 'develop' into transient
ilhamv Jul 31, 2024
447a6b1
Merge branch 'develop' into transient
ilhamv Sep 19, 2024
3b6f4df
Merge branch 'develop' into transient
ilhamv Oct 5, 2024
5caca61
Merge branch 'develop' into combing
ilhamv Oct 5, 2024
cb73ddc
Merge branch 'develop' into transient
ilhamv Nov 11, 2024
a226095
Merge branch 'transient' of https://github.com/ilhamv/openmc into tra…
ilhamv Nov 11, 2024
b611eda
Merge branch 'openmc-dev:develop' into transient
ilhamv Dec 10, 2024
05608fb
Merge branch 'openmc-dev:develop' into combing
ilhamv Dec 12, 2024
5706fb7
Merge branch 'develop' into transient
ilhamv May 29, 2025
7f37901
Merge branch 'develop' into combing
ilhamv May 29, 2025
aac0168
Merge branch 'develop' into transient
ilhamv Jul 6, 2025
2287d70
Merge branch 'develop' into pr/ilhamv/2898
paulromano Sep 12, 2025
37c1f81
Update versionadded directive
paulromano Sep 12, 2025
6c1df3b
Combine scripts in pincell_pulsed example
paulromano Sep 12, 2025
f9cfa6a
Add missing copy_ifp_data_from_fission_banks
paulromano Sep 13, 2025
09e368c
Merge branch 'develop' into pr/ilhamv/2992
paulromano Sep 13, 2025
2eed04e
Make sure parent/progeny_id are available when fission bank is stored
paulromano Sep 17, 2025
57f4263
Merge branch 'pr/ilhamv/2898' into pr/ilhamv/2992
paulromano Sep 17, 2025
bd2d092
Update regression test results
paulromano Sep 17, 2025
04b6e6e
Update hardcoded values in test_deplete_resultslist.py
paulromano Sep 17, 2025
ade9076
Handle nan in mg_convert test
paulromano Sep 16, 2025
c4065c1
Replace statepoint_batch regression test with a unit test
paulromano Sep 17, 2025
e675d59
Fix formatting
paulromano Sep 17, 2025
26763e5
Make sure max_secondaries goes to XML
paulromano Sep 17, 2025
82ef1b3
Relax tolerance on deplete_with_transfer_rates
paulromano Sep 17, 2025
3fda7a6
Further relax tolerances on deplete_with_transfer_rates
paulromano Sep 17, 2025
4a40a01
Update deplete_with_transfer_rates to use 150 particles
paulromano Sep 18, 2025
2df772d
Update ssw event-based test results
paulromano Sep 18, 2025
f380b66
Fix source for dagmc/universes test to avoid flakiness
paulromano Sep 18, 2025
82eea4f
Merge branch 'develop' into pr/ilhamv/2992
paulromano Sep 19, 2025
b8c1612
Update cpp_driver and lattice_distribrho test results
paulromano Sep 19, 2025
db1ce5f
Restore original density in test_cell_density
paulromano Sep 19, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Restore original density in test_cell_density
  • Loading branch information
paulromano committed Sep 19, 2025
commit db1ce5f9b3abc02648604f4fc91aaf3ad410983e
17 changes: 11 additions & 6 deletions tests/unit_tests/test_lib.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,16 +161,21 @@ def test_properties_temperature(lib_init):

def test_cell_density(lib_init):
cell = openmc.lib.cells[1]
cell.set_density(1.5, 0)
assert cell.get_density(0) == pytest.approx(1.5)
cell.set_density(2.0)
assert cell.get_density() == pytest.approx(2.0)
print('density', cell.get_density())
orig_density = cell.get_density()
try:
cell.set_density(1.5, 0)
assert cell.get_density(0) == pytest.approx(1.5)
cell.set_density(2.0)
assert cell.get_density() == pytest.approx(2.0)
finally:
cell.set_density(orig_density)


def test_properties_cell_density(lib_init):
# Cell density should be 2.0 from above test
cell = openmc.lib.cells[1]
assert cell.get_density() == pytest.approx(2.0)
orig_density = cell.get_density()

# Export properties and change density
openmc.lib.export_properties('properties.h5')
Expand All @@ -179,7 +184,7 @@ def test_properties_cell_density(lib_init):

# Import properties and check that density is restored
openmc.lib.import_properties('properties.h5')
assert cell.get_density() == pytest.approx(2.0)
assert cell.get_density() == pytest.approx(orig_density)


def test_new_cell(lib_init):
Expand Down