Skip to content

Commit f690295

Browse files
Merge pull request #3478 from AayushSabharwal/as/parsing-tests
test: make model parsing tests more generic
2 parents 52bb5b4 + 8f6653b commit f690295

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

test/model_parsing.jl

+4-3
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ using ModelingToolkit: get_connector_type, get_defaults, get_gui_metadata,
33
get_systems, get_ps, getdefault, getname, readable_code,
44
scalarize, symtype, VariableDescription, RegularConnector,
55
get_unit
6+
using SymbolicIndexingInterface
67
using URIs: URI
78
using Distributions
89
using DynamicQuantities, OrdinaryDiffEq
@@ -819,15 +820,15 @@ end
819820
@named guess_model = GuessModel()
820821

821822
j_guess = getguess(guess_model.j)
822-
@test typeof(j_guess) == Num
823+
@test symbolic_type(j_guess) == ScalarSymbolic()
823824
@test readable_code(j_guess) == "l(t) / i(t) + k(t)"
824825

825826
i_guess = getguess(guess_model.i)
826-
@test typeof(i_guess) == Num
827+
@test symbolic_type(i_guess) == ScalarSymbolic()
827828
@test readable_code(i_guess) == "k(t)"
828829

829830
l_guess = getguess(guess_model.l)
830-
@test typeof(l_guess) == Num
831+
@test symbolic_type(l_guess) == ScalarSymbolic()
831832
@test readable_code(l_guess) == "k(t)"
832833
end
833834

0 commit comments

Comments
 (0)