Skip to content

Commit

Permalink
tests: move out other structs
Browse files Browse the repository at this point in the history
  • Loading branch information
visr committed Nov 17, 2020
1 parent c692e67 commit d49f93d
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,15 @@ using Test
using BasicModelInterface
const BMI = BasicModelInterface

# dummy model structs to test the interface
struct UnknownModel end

struct KnownModel
waterlevel::Matrix{Float64}
end

struct MyModel end

@testset "BasicModelInterface.jl" begin

@testset "no BMI implementation" begin
Expand All @@ -15,10 +22,6 @@ struct UnknownModel end
end

@testset "some BMI implementation" begin
struct KnownModel
waterlevel::Matrix{Float64}
end

function BMI.initialize(model::KnownModel)
known_model.waterlevel[:] .= 0.0
end
Expand All @@ -32,7 +35,6 @@ end
@testset "interface functions are defined" begin
# not necessarily correct parameters
# only needed to verify that the function is defined, but does not have methods yet
struct MyModel end
model = MyModel()
time = 1.0
name = "myparam"
Expand Down

3 comments on commit d49f93d

@visr
Copy link
Member Author

@visr visr commented on d49f93d Nov 17, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@visr
Copy link
Member Author

@visr visr commented on d49f93d Nov 17, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/24803

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.1.0 -m "<description of version>" d49f93dd4208d13bd77d7f4e1e048ddbc99c0fb6
git push origin v0.1.0

Please # to comment.