mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 22:26:08 -04:00
Adding a simple CAD-based gometry unit test.
This commit is contained in:
parent
bd791ca256
commit
1fb69d0dc9
5 changed files with 73 additions and 0 deletions
BIN
tests/unit_tests/cad/dagmc.h5m
Normal file
BIN
tests/unit_tests/cad/dagmc.h5m
Normal file
Binary file not shown.
16
tests/unit_tests/cad/materials.xml
Normal file
16
tests/unit_tests/cad/materials.xml
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
<?xml version="1.0"?>
|
||||
<materials>
|
||||
|
||||
<material id="40">
|
||||
<density value="11" units="g/cc" />
|
||||
<nuclide name="U235" ao="1.0" />
|
||||
</material>
|
||||
|
||||
<material id="41">
|
||||
<density value="1.0" units="g/cc" />
|
||||
<nuclide name="H1" ao="2.0" />
|
||||
<nuclide name="O16" ao="1.0" />
|
||||
<sab name="c_H_in_H2O"/>
|
||||
</material>
|
||||
|
||||
</materials>
|
||||
16
tests/unit_tests/cad/settings.xml
Normal file
16
tests/unit_tests/cad/settings.xml
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
<?xml version="1.0"?>
|
||||
<settings>
|
||||
|
||||
<run_mode>eigenvalue</run_mode>
|
||||
<dagmc>true</dagmc>
|
||||
<batches>15</batches>
|
||||
<inactive>5</inactive>
|
||||
<particles>10000</particles>
|
||||
<!-- Starting source -->
|
||||
<source>
|
||||
<space type="box">
|
||||
<parameters>-4 -4 -4 4 4 4</parameters>
|
||||
</space>
|
||||
</source>
|
||||
|
||||
</settings>
|
||||
31
tests/unit_tests/cad/tallies.xml
Normal file
31
tests/unit_tests/cad/tallies.xml
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
<?xml version="1.0"?>
|
||||
<tallies>
|
||||
|
||||
<filter id="1" type="cell">
|
||||
<bins>1</bins>
|
||||
</filter>
|
||||
|
||||
<filter id="2" type="energy">
|
||||
<bins>0 20.0e6</bins>
|
||||
</filter>
|
||||
|
||||
<filter id="3" type="energyout">
|
||||
<bins>0 20.0e6</bins>
|
||||
</filter>
|
||||
|
||||
<tally id="1">
|
||||
<filters>1</filters>
|
||||
<scores>total scatter nu-scatter absorption fission nu-fission</scores>
|
||||
</tally>
|
||||
|
||||
<tally id="2">
|
||||
<filters>1 2</filters>
|
||||
<scores>total scatter nu-scatter absorption fission nu-fission</scores>
|
||||
</tally>
|
||||
|
||||
<tally id="3">
|
||||
<filters>1 2 3</filters>
|
||||
<scores>scatter nu-scatter nu-fission</scores>
|
||||
</tally>
|
||||
|
||||
</tallies>
|
||||
10
tests/unit_tests/cad/test_cad.py
Normal file
10
tests/unit_tests/cad/test_cad.py
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
|
||||
import pytest
|
||||
|
||||
from subprocess import call
|
||||
|
||||
from tests.unit_tests import assert_false
|
||||
|
||||
def test_cad():
|
||||
assert not call(["openmc"])
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue