Loading tests/test_files/isoxml_sample.xml 0 → 100644 +21 −0 Original line number Diff line number Diff line <ISOXML> <Multigroup_Cross_Section_Libraries Name="ISOTXS-neutron" NGroup="33"> <Multigroup_Cross_Section_Library ID="1" Ver="1.0" Generator="INL" TimeCreated="Wed Jul 20 21:02:47 2022" Description="ISOTXS"> <Tabulation>Tfuel</Tabulation> <Tfuel>300</Tfuel> <ReferenceGridIndex>1</ReferenceGridIndex> <AllReactions>Total Transport Removal Absorption NGamma N2N NAlpha NProton NDeuteron NTriton Fission nuFission kappaFission EnergyDeposition FissionSpectrum NeutronVelocity Scattering</AllReactions> <TablewiseReactions/> <LibrarywiseReactions/> <Table gridIndex="1"> <Isotope Name="pseudo_REG_A" L="1"> </Isotope> <Isotope Name="pseudo_REG_B" L="1"> </Isotope> <Isotope Name="pseudo_REG_C" Class="Structure" L="1"> </Isotope> </Table> </Multigroup_Cross_Section_Library> </Multigroup_Cross_Section_Libraries> </ISOXML> tests/test_material_report.py 0 → 100644 +8 −0 Original line number Diff line number Diff line import pytest from pygriffin.isoxml_reader import parse_isoxml def test_isoxml_materials(): exp_materials = ['pseudo_REG_A', 'pseudo_REG_B', 'pseudo_REG_C'] materials = parse_isoxml('./test_files/isoxml_sample.xml') assert exp_materials == materials No newline at end of file Loading
tests/test_files/isoxml_sample.xml 0 → 100644 +21 −0 Original line number Diff line number Diff line <ISOXML> <Multigroup_Cross_Section_Libraries Name="ISOTXS-neutron" NGroup="33"> <Multigroup_Cross_Section_Library ID="1" Ver="1.0" Generator="INL" TimeCreated="Wed Jul 20 21:02:47 2022" Description="ISOTXS"> <Tabulation>Tfuel</Tabulation> <Tfuel>300</Tfuel> <ReferenceGridIndex>1</ReferenceGridIndex> <AllReactions>Total Transport Removal Absorption NGamma N2N NAlpha NProton NDeuteron NTriton Fission nuFission kappaFission EnergyDeposition FissionSpectrum NeutronVelocity Scattering</AllReactions> <TablewiseReactions/> <LibrarywiseReactions/> <Table gridIndex="1"> <Isotope Name="pseudo_REG_A" L="1"> </Isotope> <Isotope Name="pseudo_REG_B" L="1"> </Isotope> <Isotope Name="pseudo_REG_C" Class="Structure" L="1"> </Isotope> </Table> </Multigroup_Cross_Section_Library> </Multigroup_Cross_Section_Libraries> </ISOXML>
tests/test_material_report.py 0 → 100644 +8 −0 Original line number Diff line number Diff line import pytest from pygriffin.isoxml_reader import parse_isoxml def test_isoxml_materials(): exp_materials = ['pseudo_REG_A', 'pseudo_REG_B', 'pseudo_REG_C'] materials = parse_isoxml('./test_files/isoxml_sample.xml') assert exp_materials == materials No newline at end of file