Adding a check that material filled cells return an empty result.

This commit is contained in:
Patrick Shriwise 2020-05-20 12:46:33 -05:00
parent db99148281
commit 59552944f5

View file

@ -37,6 +37,14 @@ int main(int argc, char** argv) {
auto& lattice_cell = openmc::model::cells[root_univ->cells_[0]];
lattice_cell->set_temperature(300, 1, true);
// check that material-filled cells return no contained cells
for (auto& cell : openmc::model::cells) {
if (cell->type_ == Fill::MATERIAL) {
auto contained_cells = cell->get_contained_cells();
assert(contained_cells.empty());
}
}
// the summary file will be used to check that
// temperatures were set correctly so clear
// error output can be provided