Skip to content

Commit ed947b7

Browse files
committed
fix remaining tests
1 parent 6fed777 commit ed947b7

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

Project.toml

+1
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ ForwardDiff = "0.10.3"
115115
FunctionWrappers = "1.1"
116116
FunctionWrappersWrappers = "0.1"
117117
Graphs = "1.5.2"
118+
ImplicitDiscreteSolve = "0.1.2"
118119
InfiniteOpt = "0.5"
119120
InteractiveUtils = "1"
120121
JuliaFormatter = "1.0.47"

src/systems/model_parsing.jl

+1-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ function _model_macro(mod, fullname::Union{Expr, Symbol}, expr, isconnector)
125125
@inline pop_structure_dict!.(
126126
Ref(dict), [:constants, :defaults, :kwargs, :structural_parameters])
127127

128-
sys = :($ODESystem($(flatten_equations)(equations), $iv, variables, parameters;
128+
sys = :($type($(flatten_equations)(equations), $iv, variables, parameters;
129129
name, description = $description, systems, gui_metadata = $gui_metadata,
130130
continuous_events = [$(c_evts...)], discrete_events = [$(d_evts...)],
131131
defaults))

test/fmi/fmi.jl

+2-2
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ end
158158
fmu = loadFMU(joinpath(FMU_DIR, "SimpleAdder.fmu"); type = :CS)
159159
@named adder = MTK.FMIComponent(
160160
Val(2); fmu, type = :CS, communication_step_size = 1e-6,
161-
reinitializealg = BrownFullBasicInit())
161+
reinitializealg = BrownFullBasicInit(abstol = 1e-7))
162162
@test MTK.isinput(adder.a)
163163
@test MTK.isinput(adder.b)
164164
@test MTK.isoutput(adder.out)
@@ -211,7 +211,7 @@ end
211211
fmu = loadFMU(joinpath(FMU_DIR, "StateSpace.fmu"); type = :CS)
212212
@named sspace = MTK.FMIComponent(
213213
Val(3); fmu, communication_step_size = 1e-6, type = :CS,
214-
reinitializealg = BrownFullBasicInit())
214+
reinitializealg = BrownFullBasicInit(abstol = 1e-7))
215215
@test MTK.isinput(sspace.u)
216216
@test MTK.isoutput(sspace.y)
217217
@test !MTK.isinput(sspace.x) && !MTK.isoutput(sspace.x)

0 commit comments

Comments
 (0)