Skip to content

Commit

Permalink
Added more requirements for actions, multiapps, pra, transfers, uo, a…
Browse files Browse the repository at this point in the history
…nd vpps. Refs idaholab#55, idaholab#59 and idaholab#173.
  • Loading branch information
cbolisetti committed Jun 5, 2019
1 parent 22aba22 commit b5b613c
Show file tree
Hide file tree
Showing 13 changed files with 116 additions and 0 deletions.
11 changes: 11 additions & 0 deletions test/tests/mastodonblock/combined/tests
Original file line number Diff line number Diff line change
@@ -1,16 +1,23 @@
[Tests]
design = 'syntax/Mastodon/index.md'
issues = '#50'

[./noaction]
# 1 element problem with no Mastodon block actions
type = Exodiff
input = noaction.i
exodiff = noaction_out.e

requirement = "MASTODON shall accurately evaluate a single 3D element dynamics problem when the MastodonBlock action is not used."
[../]

[./noaction_2D]
# 1 element 2D problem with no Mastodon block actions
type = Exodiff
input = noaction_2D.i
exodiff = noaction_2D_out.e

requirement = "MASTODON shall accurately evaluate a single 2D element dynamics problem when the MastodonBlock action is not used."
[../]

[./mastodon_block_actions]
Expand All @@ -20,6 +27,8 @@
exodiff = noaction_out.e
cli_args = "Outputs/file_base=noaction_out"
prereq = noaction

requirement = "Using the MastodonBlock action should produce results that are identical to those calculated without the action for a single 3D element dynamic problem."
[../]

[./mastodon_block_actions_2D]
Expand All @@ -29,5 +38,7 @@
exodiff = noaction_2D_out.e
cli_args = "Outputs/file_base=noaction_2D_out"
prereq = noaction_2D

requirement = "Using the MastodonBlock action should produce results that are identical to those calculated without the action for a single 2D element dynamic problem."
[../]
[]
17 changes: 17 additions & 0 deletions test/tests/mastodonblock/model/tests
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
[Tests]
design = 'source/actions/MastodonModelAction.md'
issues = '#50'

[./noaction_static]
# 1 element static analysis with no Mastodon/model actions
type = Exodiff
input = noaction_static.i
exodiff = noaction_static_out.e

requirements = "MASTODON shall correctly perform a 1 element 3D static analysis without MastodonModel action."
[../]

[./model_static]
Expand All @@ -13,20 +18,26 @@
exodiff = noaction_static_out.e
cli_args = "Outputs/file_base=noaction_static_out"
prereq = noaction_static

requirements = "Using the MastodonModel action for a 1 element 3D static analysis should produce results that are identical to those calculated without using the MastodonModel action."
[../]

[./noaction_dynamic]
# 1 element dynamic analysis with no Mastodon/model actions
type = Exodiff
input = noaction_dynamic.i
exodiff = noaction_dynamic_out.e

requirements = "MASTODON shall correctly perform a 1 element 3D dynamic analysis without MastodonModel action."
[../]

[./noaction_dynamic_2D]
# 1 element 2D dynamic analysis with no Mastodon/model actions
type = Exodiff
input = noaction_dynamic_2D.i
exodiff = noaction_dynamic_2D_out.e

requirements = "MASTODON shall correctly perform a 1 element 2D dynamic analysis without MastodonModel action."
[../]

[./model_dynamic]
Expand All @@ -36,6 +47,8 @@
exodiff = noaction_dynamic_out.e
cli_args = "Outputs/file_base=noaction_dynamic_out"
prereq = noaction_dynamic

requirements = "Using the MastodonModel action for a 1 element 3D dynamic analysis should produce results that are identical to those calculated without using the MastodonModel action."
[../]

[./model_dynamic_2D]
Expand All @@ -45,6 +58,8 @@
exodiff = noaction_dynamic_2D_out.e
cli_args = "Outputs/file_base=noaction_dynamic_2D_out"
prereq = noaction_dynamic_2D

requirements = "Using the MastodonModel action for a 1 element 2D dynamic analysis should produce results that are identical to those calculated without using the MastodonModel action."
[../]

[./model_dynamic_2D_dim_error]
Expand All @@ -53,6 +68,8 @@
input = model_dynamic_2D.i
cli_args = "Mastodon/Model/dim=3"
expect_err = "Error in MastodonModelAction block, Model. dim is not equal to the mesh dimension, which is 2."

requirements = "MASTODON shall throw an error when the `dim` parameter in MastodonModel action is not consistent with the dimension of the mesh in the mesh block."
[../]

[]
7 changes: 7 additions & 0 deletions test/tests/mastodonblock/outputs/tests
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
[Tests]
design = 'source/actions/MastodonOutputsAction.md'
issues = '#50'

[./noaction_stress_strain_output]
# 1 element problem with no Mastodon/Outputs actions
type = Exodiff
input = noaction_stress_strain_output.i
exodiff = noaction_stress_strain_output_out.e

requirements = "MASTODON shall correctly evaluate the outputs of a 1 element analysis when the MastodonOutputs action is not used."
[../]

[./variable_action]
Expand All @@ -13,5 +18,7 @@
exodiff = noaction_stress_strain_output_out.e
cli_args = "Outputs/file_base=noaction_stress_strain_output_out"
prereq = noaction_stress_strain_output

requirements = "Using the MastodonOutputs action for a 1 element analysis should produce results that are identical to those calculated when the MastodonOutputs action is not used."
[../]
[]
4 changes: 4 additions & 0 deletions test/tests/multiapps/hazard_curve_multiapp/tests
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
[Tests]
design = 'source/multiapps/HazardCurveMultiApp.md'
issues = '#61'
[./run]
type = CheckFiles
input = hazard_curve_master.i
Expand All @@ -22,5 +24,7 @@
hazard_curve_master_out_run_hazard17.e
hazard_curve_master_out_run_hazard18.e
hazard_curve_master_out_run_hazard19.e"

requirements = "The HazardCurveMultiApp shall execute the sub file for each ground motion in the GroundMotionReader UserObject for each bin of the HazardCurve UserObject."
[../]
[]
6 changes: 6 additions & 0 deletions test/tests/pra/tests
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# test for the PRA infrastructure in MASTODON
[Tests]
design = 'source/multiapps/HazardCurveMultiApp.md'
# Change design to SPRA documentation when written
issues = '#101'

[./pra]
type = CSVDiff
input = master.i
Expand Down Expand Up @@ -40,5 +44,7 @@
master_out_run_hazard11_sub0.csv
master_out_run_hazard11_sub1.csv
master_out_run_hazard11_sub2.csv"

requirements = "MASTODON shall perform probabilistic simulations for seismic probabilistic risk assessment for a given hazard curve, number of bins, ground motions and a finite element model."
[../]
[]
4 changes: 4 additions & 0 deletions test/tests/transfers/hazard_curve_transfer/tests
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
[Tests]
design = 'source/transfers/HazardCurveTransfer.md'
issues = '#61'
[./run]
type = CSVDiff
input = hazard_curve_master.i
Expand All @@ -22,5 +24,7 @@
hazard_curve_master_out_run_hazard17.csv
hazard_curve_master_out_run_hazard18.csv
hazard_curve_master_out_run_hazard19.csv"

requirements = "The HazardCurve transfer shall scale the ground motions from the GroundMotionReader UserObject according to the hazard curve in the Hazard UserObject and transfer the ground motions to the sub file."
[../]
[]
7 changes: 7 additions & 0 deletions test/tests/transfers/piecewise_function/tests
Original file line number Diff line number Diff line change
@@ -1,12 +1,19 @@
[Tests]
design = 'source/transfers/PiecewiseFunctionTransfer.md'
issues = '#123'

[to_multiapp]
type = CSVDiff
input = to_master.i
csvdiff = 'to_master_out.csv to_master_out_sub0.csv'

requirements = "The PiecewiseFunctionTransfer shall transfer a PiecewiseLinear function value from a sub to the master file."
[]
[from_multiapp]
type = CSVDiff
input = from_master.i
csvdiff = 'from_master_out.csv from_master_out_sub0.csv'

requirements = "The PiecewiseFunctionTransfer shall transfer a PiecewiseLinear function value from a master to the sub file."
[]
[]
8 changes: 8 additions & 0 deletions test/tests/userobjects/ground_motion_reader/tests
Original file line number Diff line number Diff line change
@@ -1,12 +1,20 @@
[Tests]
design = "source/userobjects/GroundMotionReader.md"
issues = '#61'

[./run]
type = RunApp
input = ground_motion_reader.i

requirements = "The GroundMotionReader object shall run without errors."
[../]

[./bad_pattern]
type = RunException
input = ground_motion_reader.i
cli_args = UserObjects/motions/pattern=this/is/wrong*.csv
expect_err = "Unable to locate files with the given pattern \(this/is/wrong\*\.csv\) in the GroundMotionReader object 'motions'."

requirements = "The GroundMotionReader object shall throw an error when the ground motion files with the provided pattern are not found."
[../]
[]
8 changes: 8 additions & 0 deletions test/tests/userobjects/hazard_curve/tests
Original file line number Diff line number Diff line change
@@ -1,12 +1,20 @@
[Tests]
design = "source/userobjects/HazardCurve.md"
issues = '#61'

[./run]
type = RunApp
input = hazard_curve.i

requirements = "The HazardCurve userobject shall run without errors."
[../]

[./ref_size_error]
type = RunException
input = hazard_curve.i
cli_args = "UserObjects/hazard/reference_acceleration='1 2 3 4 5 6 7'"
expect_err = "The 'reference_acceleration' input must \(size: 7\) in the 'hazard' block should be a scalar or a vector equal to the length of the prescribed number of bins \(5\)."

requirements = "The HazardCurve userobject shall throw an error when the `reference_acceleration` input is not a scalar, or a vector of the size equal to the number of bins."
[../]
[]
5 changes: 5 additions & 0 deletions test/tests/vectorpostprocessors/fragility/tests
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
# Test for Fragility VectorPostprocessor
[Tests]
design = "source/vectorpostprocessors/Fragility.md"
issues = '#44'

[./fragility]
type = CSVDiff
input = fragility.i
csvdiff = fragility_out_fragility_pump_0002.csv
boost = true

requirements = "The Fragility vectorpostprocessor shall accurately evaluate the median demands, beta, and the conditional probability of failure of the SSC at each intensity, and the median and beta of the enhanced fragility fit for the SSC."
[../]
[]
14 changes: 14 additions & 0 deletions test/tests/vectorpostprocessors/housner_spectrum_intensity/tests
Original file line number Diff line number Diff line change
@@ -1,30 +1,44 @@
[Tests]
design = "source/vectorpostprocessors/HousnerSpectrumIntensity.md"
issues = '#39'

[./hsi]
type = CSVDiff
input = housner_spectrum_intensity.i
csvdiff = housner_spectrum_intensity_out_accel_hsi.csv

requirements = "The HSICalculator vectorpostprocessor shall accurately calculate the HSI of a response history on a serial execution."
[../]

[./hsi_parallel]
type = CSVDiff
input = housner_spectrum_intensity.i
csvdiff = housner_spectrum_intensity_out_accel_hsi.csv
prereq = hsi
min_parallel = 3
max_parallel = 3

requirements = "The HSICalculator vectorpostprocessor shall accurately calculate the HSI of a response history on a parallel execution."
[../]

[./hsi_threads]
type = CSVDiff
input = housner_spectrum_intensity.i
csvdiff = housner_spectrum_intensity_out_accel_hsi.csv
prereq = hsi_parallel
min_threads = 3

requirements = "The HSICalculator vectorpostprocessor shall accurately calculate the HSI of a response history on a parallel execution."
[../]

[./hsi_threads_parallel]
type = CSVDiff
input = housner_spectrum_intensity.i
csvdiff = housner_spectrum_intensity_out_accel_hsi.csv
prereq = hsi_threads
min_threads = 3
min_parallel = 2

requirements = "The HSICalculator vectorpostprocessor shall accurately calculate the HSI of a response history on a parallel execution."
[../]
[]
14 changes: 14 additions & 0 deletions test/tests/vectorpostprocessors/response_history_builder/tests
Original file line number Diff line number Diff line change
@@ -1,30 +1,44 @@
[Tests]
design = "source/vectorpostprocessors/ResponseHistoryBuilder.md"
issues = '#35'

[./builder]
type = CSVDiff
input = response_history_builder.i
csvdiff = 'response_history_builder_out_accel_nodes.csv response_history_builder_out_accel_bnd.csv'

requirements = "The ResponseHistoryBuilder vectorpostprocessor shall accurately evaluate the response histories for node input as well as boundary input during a serial execution."
[../]

[./builder_parallel]
type = CSVDiff
input = response_history_builder.i
csvdiff = 'response_history_builder_out_accel_nodes.csv response_history_builder_out_accel_bnd.csv'
prereq = builder
min_parallel = 3
max_parallel = 3

requirements = "The ResponseHistoryBuilder vectorpostprocessor shall accurately evaluate the response histories for node input as well as boundary input during a parallel execution."
[../]

[./builder_threads]
type = CSVDiff
input = response_history_builder.i
csvdiff = 'response_history_builder_out_accel_nodes.csv response_history_builder_out_accel_bnd.csv'
prereq = builder_parallel
min_threads = 6

requirements = "The ResponseHistoryBuilder vectorpostprocessor shall accurately evaluate the response histories for node input as well as boundary input during a parallel execution."
[../]

[./builder_threads_parallel]
type = CSVDiff
input = response_history_builder.i
csvdiff = 'response_history_builder_out_accel_nodes.csv response_history_builder_out_accel_bnd.csv'
prereq = builder_threads
min_threads = 4
min_parallel = 2

requirements = "The ResponseHistoryBuilder vectorpostprocessor shall accurately evaluate the response histories for node input as well as boundary input during a parallel execution."
[../]
[]
11 changes: 11 additions & 0 deletions test/tests/vectorpostprocessors/response_spectra_calculator/tests
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
[Tests]
design = 'source/vectorpostprocessors/ResponseSpectraCalculator.md'
issues = '#36'

[./spectrum]
type = CSVDiff
input = response_spectra_calculator.i
csvdiff = response_spectra_calculator_out_accel_spec.csv

requirements = "The ResponseSpectraCalculator vectorpostprocessor shall accurately calculate the response spectra during a serial execution."
[../]
[./spectrum_parallel]
type = CSVDiff
Expand All @@ -11,13 +16,17 @@
prereq = spectrum
min_parallel = 3
max_parallel = 3

requirements = "The ResponseSpectraCalculator vectorpostprocessor shall accurately calculate the response spectra during a parallel execution."
[../]
[./spectrum_threads]
type = CSVDiff
input = response_spectra_calculator.i
csvdiff = response_spectra_calculator_out_accel_spec.csv
prereq = spectrum_parallel
min_threads = 3

requirements = "The ResponseSpectraCalculator vectorpostprocessor shall accurately calculate the response spectra during a parallel execution."
[../]
[./spectrum_threads_parallel]
type = CSVDiff
Expand All @@ -26,5 +35,7 @@
prereq = spectrum_threads
min_threads = 3
min_parallel = 2

requirements = "The ResponseSpectraCalculator vectorpostprocessor shall accurately calculate the response spectra during a parallel execution."
[../]
[]

0 comments on commit b5b613c

Please sign in to comment.