Skip to content

Commit 7c164d3

Browse files
AnnikaSchultheissjohn-hen
authored andcommitted
Fix use of deprecated function ´clearSolution´ and replace by ´clearSolutionData´.
1 parent 3bc000e commit 7c164d3

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

mph/model.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -912,7 +912,7 @@ def clear(self):
912912
log.info('Finished clearing plots.')
913913
log.info('Clearing solution data.')
914914
for solution in self/'solutions':
915-
solution.java.clearSolution()
915+
solution.java.clearSolutionData()
916916
log.info('Finished clearing solutions.')
917917
log.info('Clearing mesh data.')
918918
for mesh in self/'meshes':

tests/test_model.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ def test_evaluate():
360360
model.evaluate('U', dataset=no_solution)
361361
no_solution.remove()
362362
solution = model/'solutions'/'electrostatic solution'
363-
solution.java.clearSolution()
363+
solution.java.clearSolutionData()
364364
with raises(RuntimeError):
365365
model.evaluate('U')
366366
model.solve('static')

tests/test_node.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ def test_problems():
218218
anode.property('V0', '+U/2')
219219
study.run()
220220
assert not root.problems()
221-
solver.parent().java.clearSolution()
221+
solver.parent().java.clearSolutionData()
222222

223223

224224
def test_rename():

0 commit comments

Comments
 (0)