Skip to content

Commit 40feb08

Browse files
committed
#858 not testing solver anymore
1 parent 6da78cb commit 40feb08

File tree

1 file changed

+0
-20
lines changed

1 file changed

+0
-20
lines changed

tests/unit/test_solvers/test_casadi_solver.py

-20
Original file line numberDiff line numberDiff line change
@@ -309,26 +309,6 @@ def test_model_solver_with_non_identity_mass(self):
309309
np.testing.assert_allclose(solution.y[0], np.exp(0.1 * solution.t))
310310
np.testing.assert_allclose(solution.y[-1], 2 * np.exp(0.1 * solution.t))
311311

312-
def test_model_solver_with_dvdt(self):
313-
model = pybamm.BaseModel()
314-
var1 = pybamm.Variable("var1", domain="negative electrode")
315-
var2 = pybamm.Variable("var2", domain="negative electrode")
316-
model.rhs = {var1: -2 * var1 * pybamm.t}
317-
model.algebraic = {var2: var2 - var1.diff(pybamm.t)}
318-
model.initial_conditions = {var1: 1, var2: 0}
319-
pybamm.make_semi_explicit(model)
320-
disc = get_discretisation_for_testing()
321-
disc.process_model(model)
322-
323-
# Solve
324-
solver = pybamm.CasadiSolver(rtol=1e-8, atol=1e-8)
325-
t_eval = np.linspace(0, 1, 100)
326-
solution = solver.solve(model, t_eval)
327-
np.testing.assert_array_equal(solution.t, t_eval)
328-
np.testing.assert_allclose(solution.y[0], np.exp(-solution.t**2), rtol=1e-06)
329-
np.testing.assert_allclose(solution.y[-1],
330-
-2 * solution.t * np.exp(-solution.t**2), rtol=1e-06)
331-
332312

333313
if __name__ == "__main__":
334314
print("Add -v for more debug output")

0 commit comments

Comments
 (0)