armi.operators.tests.test_operators module¶
Tests for operators
- class armi.operators.tests.test_operators.InterfaceA(r, cs)[source]¶
Bases:
armi.interfaces.Interface
Construct an interface.
The
r
andcs
arguments are required, but may beNone
, where appropriate for the specificInterface
implementation.- Parameters
r (Reactor) – A reactor to attach to
cs (Settings) – Settings object to use
- Raises
RuntimeError – Interfaces derived from Interface must define their name
- function = 'A'¶
The function performed by an Interface. This is not required be be defined by implementations of Interface, but is used to form categories of interfaces.
- class armi.operators.tests.test_operators.InterfaceB(r, cs)[source]¶
Bases:
armi.operators.tests.test_operators.InterfaceA
Dummy Interface that extends A
Construct an interface.
The
r
andcs
arguments are required, but may beNone
, where appropriate for the specificInterface
implementation.- Parameters
r (Reactor) – A reactor to attach to
cs (Settings) – Settings object to use
- Raises
RuntimeError – Interfaces derived from Interface must define their name
- function = 'A'¶
The function performed by an Interface. This is not required be be defined by implementations of Interface, but is used to form categories of interfaces.
- class armi.operators.tests.test_operators.InterfaceC(r, cs)[source]¶
Bases:
armi.interfaces.Interface
Construct an interface.
The
r
andcs
arguments are required, but may beNone
, where appropriate for the specificInterface
implementation.- Parameters
r (Reactor) – A reactor to attach to
cs (Settings) – Settings object to use
- Raises
RuntimeError – Interfaces derived from Interface must define their name
- function = 'A'¶
The function performed by an Interface. This is not required be be defined by implementations of Interface, but is used to form categories of interfaces.
- class armi.operators.tests.test_operators.OperatorTests(methodName='runTest')[source]¶
Bases:
unittest.case.TestCase
Create an instance of the class that will use the named test method when executed. Raises a ValueError if the instance does not have a method with the specified name.
- class armi.operators.tests.test_operators.CyclesSettingsTests(methodName='runTest')[source]¶
Bases:
unittest.case.TestCase
Check that we can correctly access the various cycle settings from the operator.
Create an instance of the class that will use the named test method when executed. Raises a ValueError if the instance does not have a method with the specified name.
- detailedCyclesSettings = '\nmetadata:\n version: uncontrolled\nsettings:\n power: 1000000000.0\n nCycles: 3\n cycles:\n - name: startup sequence\n cumulative days: [1, 2, 3]\n power fractions: [0.1, 0.2, 0.3]\n availability factor: 0.1\n - cycle length: 10\n burn steps: 5\n power fractions: [0.2, 0.2, 0.2, 0.2, 0]\n availability factor: 0.5\n - name: prepare for shutdown\n step days: [3, R4]\n power fractions: [0.3, R4]\n runType: Standard\n'¶
- powerFractionsSolution = [[0.1, 0.2, 0.3], [0.2, 0.2, 0.2, 0.2, 0], [0.3, 0.3, 0.3, 0.3, 0.3]]¶
- cycleNamesSolution = ['startup sequence', None, 'prepare for shutdown']¶
- availabilityFactorsSolution = [0.1, 0.5, 1]¶
- stepLengthsSolution = [[1, 1, 1], [1.0, 1.0, 1.0, 1.0, 1.0], [3, 3, 3, 3, 3]]¶
- cycleLengthsSolution = [30, 10, 15]¶
- burnStepsSolution = [3, 5, 5]¶
- maxBurnStepsSolution = 5¶