Expose explosive release balance interfaces
This commit is contained in:
@@ -33,6 +33,8 @@ def main() -> int:
|
||||
raise AssertionError("Python wrapper is missing Gas extended C ABI diagnostics")
|
||||
if not hasattr(solver.lib, "sphlite_get_explosive_summary"):
|
||||
raise AssertionError("Python wrapper is missing Explosive C ABI diagnostics")
|
||||
if not hasattr(solver.lib, "sphlite_get_explosive_release_balance"):
|
||||
raise AssertionError("Python wrapper is missing Explosive release C ABI")
|
||||
if not hasattr(solver.lib, "sphlite_set_ignition_point"):
|
||||
raise AssertionError("Python wrapper is missing Explosive ignition C ABI")
|
||||
if solver.version() != (0, 4, 1):
|
||||
@@ -59,6 +61,8 @@ def main() -> int:
|
||||
raise AssertionError("inspect helper did not include Gas extended diagnostics")
|
||||
if "explosive_particles" not in solid_summary or "explosive_lambda_range" not in solid_summary:
|
||||
raise AssertionError("inspect helper did not include Explosive diagnostics")
|
||||
if "explosive_release_mass_values" not in solid_summary:
|
||||
raise AssertionError("inspect helper did not include Explosive release balance")
|
||||
solver.set_output_directory(root / "build-codex-unix")
|
||||
solver.write_output(0, 0.0)
|
||||
restart = root / "build-codex-unix" / "python_restart.tmp"
|
||||
@@ -135,6 +139,11 @@ def main() -> int:
|
||||
raise AssertionError("explosive summary lambda mismatch")
|
||||
if explosive_summary["explosive_released_totals"][1] <= 0.0:
|
||||
raise AssertionError("explosive summary energy mismatch")
|
||||
explosive_balance = explosive.explosive_release_balance()
|
||||
if explosive_balance["explosive_release_mass_values"][0] <= 0.0:
|
||||
raise AssertionError("explosive release balance mass mismatch")
|
||||
if explosive_balance["explosive_release_energy_values"][0] <= 0.0:
|
||||
raise AssertionError("explosive release balance energy mismatch")
|
||||
finally:
|
||||
explosive.finalize()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user