Skip to content

Commit

Permalink
test: fix bug in the tests
Browse files Browse the repository at this point in the history
  • Loading branch information
tpoisot committed Jun 30, 2023
1 parent cee39e6 commit bc35d8d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/data/mangal.jl
Original file line number Diff line number Diff line change
Expand Up @@ -71,23 +71,23 @@ mangalnetwork(name::String, args...; kwargs...) = mangalnetwork(Mangal.network(n
@test eltype(mangalnetwork(problematic_network).edges) <: AbstractFloat
end

@testitem "We can get a network by taxon" begin
@testitem "We can get a network to return reference taxon nodes" begin
import SpeciesInteractionNetworks.Mangal
network = first(Mangal.networks())
N = mangalnetwork(network; taxonlevel=true)
@test typeof(N.nodes) == Mangal.MangalReferenceTaxon
@test eltype(N.nodes) == Mangal.MangalReferenceTaxon
end

@testitem "We can get a network by name" begin
import SpeciesInteractionNetworks.Mangal
network = first(Mangal.networks())
N = mangalnetwork(network.name; taxonlevel=true)
@test typeof(N.nodes) == Mangal.MangalReferenceTaxon
@test eltype(N.nodes) == Mangal.MangalReferenceTaxon
end

@testitem "We can get a network by ID" begin
import SpeciesInteractionNetworks.Mangal
network = first(Mangal.networks())
N = mangalnetwork(network.id; taxonlevel=true)
@test typeof(N.nodes) == Mangal.MangalReferenceTaxon
@test eltype(N.nodes) == Mangal.MangalReferenceTaxon
end

0 comments on commit bc35d8d

Please sign in to comment.