Skip to content

Commit f6fea58

Browse files
test: fix tests
1 parent 5cae853 commit f6fea58

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

test/distributed.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,4 @@ end
3333
solve_lorenz(ode_prob)
3434

3535
future = @spawn solve_lorenz(ode_prob)
36-
@test_broken fetch(future)
36+
fetch(future)

test/inversemodel.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ using ModelingToolkit
22
using ModelingToolkitStandardLibrary
33
using ModelingToolkitStandardLibrary.Blocks
44
using OrdinaryDiffEq
5+
using SymbolicIndexingInterface
56
using Test
67
using ControlSystemsMTK: tf, ss, get_named_sensitivity, get_named_comp_sensitivity
78

@@ -144,7 +145,7 @@ sol = solve(prob, Rodas5P())
144145
# plot(sol, idxs=[model.tank.xc, model.tank.xT, model.controller.ctr_output.u], layout=3, sp=[1 2 3])
145146
# hline!([prob[cm.ref.k]], label="ref", sp=1)
146147

147-
@test sol(tspan[2], idxs = cm.tank.xc)prob[cm.ref.k] atol=1e-2 # Test that the inverse model led to the correct reference
148+
@test sol(tspan[2], idxs = cm.tank.xc) getp(prob, cm.ref.k)(prob) atol=1e-2 # Test that the inverse model led to the correct reference
148149

149150
Sf, simplified_sys = Blocks.get_sensitivity_function(model, :y) # This should work without providing an operating opint containing a dummy derivative
150151
x, p = ModelingToolkit.get_u0_p(simplified_sys, op)

0 commit comments

Comments
 (0)