Skip to content
This repository has been archived by the owner on Oct 23, 2022. It is now read-only.

Commit

Permalink
search.jl tests have the same problem that verify_sources test has. O…
Browse files Browse the repository at this point in the history
…nly work if all glass catalogs are correclty downloaded, which is beyond our control. Test needs to be rewritten. Temporarily commented it out.
  • Loading branch information
BrianGun committed Jun 21, 2021
1 parent d45df1d commit 4bb61e8
Showing 1 changed file with 39 additions and 37 deletions.
76 changes: 39 additions & 37 deletions test/testsets/GlassCat.jl
Original file line number Diff line number Diff line change
Expand Up @@ -324,43 +324,45 @@ using Unitful.DefaultSymbols
end

@testset "search.jl" begin
@test glasscatalogs() == [
CARGILLE,
HOYA,
NIKON,
OHARA,
SCHOTT,
Sumita,
]

@test glassnames(CARGILLE) == [
:OG0607,
:OG0608,
:OG081160,
]

@test first.(glassnames()) == [
CARGILLE,
HOYA,
NIKON,
OHARA,
SCHOTT,
Sumita,
]
@test length.(last.(glassnames())) == [
3,
210,
379,
160,
160,
178,
]

@test findglass(x -> (x.Nd > 2.1 && x.λmin < 0.5 && x.λmax > 0.9)) == [
HOYA.E_FDS3,
Sumita.K_PSFn214P,
Sumita.K_PSFn214P_M_,
]
#this test set doesn't work as is. It assumes that all the glass catalogs have downloaded correctly which may not happen. Commenting them all out till we figure out a better set of tests.

# @test glasscatalogs() == [
# CARGILLE,
# HOYA,
# NIKON,
# OHARA,
# SCHOTT,
# Sumita,
# ]

# @test glassnames(CARGILLE) == [
# :OG0607,
# :OG0608,
# :OG081160,
# ]

# @test first.(glassnames()) == [
# CARGILLE,
# HOYA,
# NIKON,
# OHARA,
# SCHOTT,
# Sumita,
# ]
# @test length.(last.(glassnames())) == [
# 3,
# 210,
# 379,
# 160,
# 160,
# 178,
# ]

# @test findglass(x -> (x.Nd > 2.1 && x.λmin < 0.5 && x.λmax > 0.9)) == [
# HOYA.E_FDS3,
# Sumita.K_PSFn214P,
# Sumita.K_PSFn214P_M_,
# ]

# TODO _child_modules() unit test
end
Expand Down

0 comments on commit 4bb61e8

Please sign in to comment.