moose
moose copied to clipboard
Add 'output_dir' parameter to FileTester
Reason
Sometimes output resides in a subdirectory, with respect to the tests files, such as output/. In this case, if you specify the output file to check against a gold file, such as
[Tests]
[mytest]
type = CSVDiff
csvdiff = 'output/myfile.csv'
[]
[]
then the tester looks for the gold file at gold/output/myfile.csv. It would be ideal for the gold file not to require a subdirectory: gold/myfile.csv.
Design
This would add a parameter output_dir to FileTester to specify where to look for the output file. Then a user could do
[Tests]
[mytest]
type = CSVDiff
output_dir = 'output'
csvdiff = 'myfile.csv'
[]
[]
Impact
Avoids needing strange workarounds in relevant situations.
I've ran into a use case where this feature would be useful for me as well.