Skip to content

Commit

Permalink
complement test update to qualify complement function with NeuralVeri…
Browse files Browse the repository at this point in the history
…fication.
  • Loading branch information
castrong committed Apr 29, 2021
1 parent 457a556 commit 63b6541
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions test/complements.jl
Expand Up @@ -9,8 +9,8 @@
@test [5.0, 5.0] HS && [5.0, 5.0] PC
@test [-1.0, -1.0] HS && [-1.0, -1.0] PC

@test complement(PC) == HS
@test complement(HS) == PC
@test NeuralVerification.complement(PC) == HS
@test NeuralVerification.complement(HS) == PC

# Hyperrectangle contained in HS
hr = Hyperrectangle(low = [1.0, 1.0], high = [2.0, 2.0])
Expand All @@ -28,11 +28,11 @@
@test !(hr HS)

# Test some other sets
@test @no_error complement(Hyperrectangle(ones(2), ones(2)))
@test @no_error complement(Ball2(ones(2), 1.0))
@test @no_error complement(Ball1(ones(3), 1.0))
@test @no_error complement(Zonotope(ones(4), ones(4, 2)))
@test @no_error complement(convert(HPolytope, hr))
@test @no_error NeuralVerification.complement(Hyperrectangle(ones(2), ones(2)))
@test @no_error NeuralVerification.complement(Ball2(ones(2), 1.0))
@test @no_error NeuralVerification.complement(Ball1(ones(3), 1.0))
@test @no_error NeuralVerification.complement(Zonotope(ones(4), ones(4, 2)))
@test @no_error NeuralVerification.complement(convert(HPolytope, hr))
end

@testset "Solvers with PCs" begin
Expand Down

0 comments on commit 63b6541

Please sign in to comment.