Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
LasNikas committed Aug 2, 2024
1 parent a581b32 commit 2789b21
Show file tree
Hide file tree
Showing 4 changed files with 4,117 additions and 4,900 deletions.
Binary file modified examples/preprocessing/data/bar.stl
Binary file not shown.
3 changes: 1 addition & 2 deletions src/setups/complex_shape.jl
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ function ComplexShape(geometry::Union{TriangleMesh, Polygon}; particle_spacing,

return sample(geometry; particle_spacing, density, pressure, mass, velocity,
point_in_geometry_algorithm, store_winding_number, grid_offset,
max_nparticles,
padding=pad_initial_particle_grid)
max_nparticles, padding=pad_initial_particle_grid)
end

function sample(geometry; particle_spacing, density, pressure=0.0, mass=nothing,
Expand Down
4 changes: 2 additions & 2 deletions test/setups/complex_shape.jl
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@

geometry = load_geometry(joinpath(data_dir, files[i] * ".stl"))

shape_sampled = ComplexShape(geometry;
shape_sampled = ComplexShape(geometry; grid_offset=0.1,
particle_spacing=particle_spacings[i],
density=1.0)
@test isapprox(shape_sampled.coordinates, coords, atol=1e-3)
Expand All @@ -112,7 +112,7 @@

shape_sampled = ComplexShape(geometry;
particle_spacing=particle_spacings[i],
density=1.0,
density=1.0, grid_offset=0.1,
point_in_geometry_algorithm=WindingNumberJacobson(;
geometry,
winding_number_factor=0.1,
Expand Down
Loading

0 comments on commit 2789b21

Please sign in to comment.