diff --git a/Examples/Tests/electrostatic_dirichlet_bc/analysis.py b/Examples/Tests/electrostatic_dirichlet_bc/analysis.py index 82fe061c3a8..f27e79012c1 100755 --- a/Examples/Tests/electrostatic_dirichlet_bc/analysis.py +++ b/Examples/Tests/electrostatic_dirichlet_bc/analysis.py @@ -14,10 +14,15 @@ # Possible running time: ~ 19 s import glob +import os +import sys import numpy as np import yt +sys.path.insert(1, "../../../../warpx/Regression/Checksum/") +import checksumAPI + files = sorted(glob.glob("diags/diag1*"))[1:] assert len(files) > 0 @@ -39,3 +44,8 @@ assert np.allclose(potentials_lo, expected_potentials_lo, rtol=0.1) assert np.allclose(potentials_hi, expected_potentials_hi, rtol=0.1) + +# compare checksums +testname = os.path.split(os.getcwd())[1] +filename = sys.argv[1] +checksumAPI.evaluate_checksum(testname, filename) diff --git a/Regression/Checksum/benchmarks_json/test_2d_dirichlet_bc.json b/Regression/Checksum/benchmarks_json/test_2d_dirichlet_bc.json new file mode 100644 index 00000000000..41567dc3bf2 --- /dev/null +++ b/Regression/Checksum/benchmarks_json/test_2d_dirichlet_bc.json @@ -0,0 +1,5 @@ +{ + "lev=0": { + "phi": 10817.97280547637 + } +} diff --git a/Regression/Checksum/benchmarks_json/test_2d_dirichlet_bc_picmi.json b/Regression/Checksum/benchmarks_json/test_2d_dirichlet_bc_picmi.json new file mode 100644 index 00000000000..41567dc3bf2 --- /dev/null +++ b/Regression/Checksum/benchmarks_json/test_2d_dirichlet_bc_picmi.json @@ -0,0 +1,5 @@ +{ + "lev=0": { + "phi": 10817.97280547637 + } +}