Skip to content

Commit

Permalink
Updating tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mitchphillipson committed Jan 17, 2024
1 parent bb57871 commit 45d610b
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 92 deletions.
79 changes: 0 additions & 79 deletions test/Untitled-1.ipynb

This file was deleted.

14 changes: 7 additions & 7 deletions test/activate.jl
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
@testset "Loading and unloading a model" begin
GU = GamsUniverse()

@create_set!(GU,:i,"Test Set",begin
a,"elm"
b,"elm2"
@set(GU, i,"Test Set",begin
a, "elm"
b, "elm2"
end)

alias(GU,:i,:j)



@create_parameters(GU,begin
:p, (:i,:j), "test parm"
@parameters(GU,begin
p, (:i,:j), (description = "test parm",)
end)

deactivate(GU,:i,:a)


@create_parameters(GU,begin
:q, (:i,:j), "test parm"
@parameters(GU,begin
q, (:i,:j), (description = "test parm",)
end)

@test GU[:p][:i,:j] == [0 0]
Expand Down
12 changes: 6 additions & 6 deletions test/load_unload.jl
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
@testset "Loading and unloading a model" begin
GU = GamsUniverse()

@create_set!(GU,:i,"Test Set",begin
@set(GU, I,"Test Set",begin
a,"elm"
b,"elm2"
end)

alias(GU,:i,:j)
@alias(GU, I, J)

@create_parameters(GU,begin
:p, (:i,:j), "test parm"
@parameters(GU,begin
p, (:I,:J), (description = "test parm",)
end)


cnt = 1
for iGU[:i],jGU[:j]
GU[:p][[i],[j]] = cnt
for iI,jJ
p[i,j] = cnt
cnt+=1
end

Expand Down

0 comments on commit 45d610b

Please sign in to comment.