Skip to content

Commit

Permalink
Use an optional arg for SupportStatus in runtests
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeingold committed Dec 8, 2024
1 parent 4099736 commit e04b75b
Showing 1 changed file with 24 additions and 24 deletions.
48 changes: 24 additions & 24 deletions test/combinations.jl
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ This file includes tests for:

function runtests(
testable::TestableGeometry,
supports::SupportStatus;
supports::SupportStatus = SupportStatus(testable.geometry);
rtol = sqrt(eps())
)
# Test alias functions
Expand Down Expand Up @@ -141,7 +141,7 @@ end #testsnippet

# Package and run tests
testable = TestableGeometry(integrand, ball, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

@testitem "Meshes.Ball 3D" setup=[Combinations] begin
Expand All @@ -164,7 +164,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, ball, solution)
runtests(testable, SupportStatus(:volume))
runtests(testable)
end

@testitem "Meshes.BezierCurve" setup=[Combinations] begin
Expand Down Expand Up @@ -251,7 +251,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, circle, solution)
runtests(testable, SupportStatus(:line))
runtests(testable)
end

@testitem "Meshes.Cone" setup=[Combinations] begin
Expand All @@ -270,7 +270,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, cone, solution)
runtests(testable, SupportStatus(:volume))
runtests(testable)
end

@testitem "Meshes.ConeSurface" setup=[Combinations] begin
Expand Down Expand Up @@ -304,7 +304,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, cyl, solution)
runtests(testable, SupportStatus(:volume))
runtests(testable)
end

@testitem "Meshes.CylinderSurface" setup=[Combinations] begin
Expand All @@ -319,7 +319,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, cyl, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

@testitem "Meshes.Disk" setup=[Combinations] begin
Expand All @@ -340,7 +340,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, disk, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

@testitem "Meshes.Ellipsoid" setup=[Combinations] begin
Expand Down Expand Up @@ -402,7 +402,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, hexahedron, solution)
runtests(testable, SupportStatus(:volume))
runtests(testable)
end

@testitem "Meshes.Line" setup=[Combinations] begin
Expand All @@ -420,7 +420,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, line, solution)
runtests(testable, SupportStatus(:line))
runtests(testable)
end

@testitem "Meshes.ParaboloidSurface" setup=[Combinations] begin
Expand All @@ -433,7 +433,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, parab, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

@testitem "ParametrizedCurve" setup=[Combinations] begin
Expand All @@ -459,9 +459,9 @@ end

# Package and run tests
testable_cart = TestableGeometry(integrand, curve_cart, solution)
runtests(testable_cart, SupportStatus(:line))
runtests(testable_cart)
testable_polar = TestableGeometry(integrand, curve_polar, solution)
runtests(testable_polar, SupportStatus(:line))
runtests(testable_polar)
end
end

Expand All @@ -480,7 +480,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, plane, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

@testitem "Meshes.Quadrangle" setup=[Combinations] begin
Expand All @@ -498,7 +498,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, quadrangle, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

@testitem "Meshes.Ray" setup=[Combinations] begin
Expand All @@ -516,7 +516,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, ray, solution)
runtests(testable, SupportStatus(:line))
runtests(testable)
end

@testitem "Meshes.Ring" setup=[Combinations] begin
Expand All @@ -536,7 +536,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, ring, solution)
runtests(testable, SupportStatus(:line))
runtests(testable)
end

@testitem "Meshes.Rope" setup=[Combinations] begin
Expand All @@ -556,7 +556,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, rope, solution)
runtests(testable, SupportStatus(:line))
runtests(testable)
end

@testitem "Meshes.Segment" setup=[Combinations] begin
Expand All @@ -576,7 +576,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, segment, solution)
runtests(testable, SupportStatus(:line))
runtests(testable)
end

@testitem "Meshes.Sphere 2D" setup=[Combinations] begin
Expand All @@ -594,7 +594,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, sphere, solution)
runtests(testable, SupportStatus(:line))
runtests(testable)
end

@testitem "Meshes.Sphere 3D" setup=[Combinations] begin
Expand All @@ -617,7 +617,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, sphere, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

@testitem "Meshes.Tetrahedron" setup=[Combinations] begin
Expand All @@ -634,7 +634,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, tetrahedron, solution)
runtests(testable, SupportStatus(:volume))
runtests(testable)
end

@testitem "Meshes.Torus" setup=[Combinations] begin
Expand All @@ -649,7 +649,7 @@ end

# Package and run tests
testable = TestableGeometry(integrand, torus, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

@testitem "Meshes.Triangle" setup=[Combinations] begin
Expand All @@ -665,5 +665,5 @@ end

# Package and run tests
testable = TestableGeometry(integrand, triangle, solution)
runtests(testable, SupportStatus(:surface))
runtests(testable)
end

0 comments on commit e04b75b

Please sign in to comment.