diff test/Grids/equidistant_grid_test.jl @ 1877:21e5fe1545c0 refactor/lazy_tensors/elementwise_ops

Merge default
author Jonatan Werpers <jonatan@werpers.com>
date Mon, 27 Jan 2025 16:56:04 +0100
parents 871f3f1decea
children edee7d677efb f93ba5832146
line wrap: on
line diff
--- a/test/Grids/equidistant_grid_test.jl	Fri Jan 10 19:45:11 2025 +0100
+++ b/test/Grids/equidistant_grid_test.jl	Mon Jan 27 16:56:04 2025 +0100
@@ -74,13 +74,16 @@
 
     @testset "boundary_indices" begin
         g = EquidistantGrid(0:0.1:1)
-        @test boundary_indices(g, LowerBoundary()) == (1,)
-        @test boundary_indices(g, UpperBoundary()) == (11,)
+        @test boundary_indices(g, LowerBoundary()) == 1
+        @test boundary_indices(g, UpperBoundary()) == 11
+
+        gf = collect(g)
+        @test gf[boundary_indices(g, LowerBoundary())] == gf[1]
+        @test gf[boundary_indices(g, UpperBoundary())] == gf[11]
 
         g = EquidistantGrid(2:0.1:10)
-        @test boundary_indices(g, LowerBoundary()) == (1,)
-        @test boundary_indices(g, UpperBoundary()) == (81,)
-
+        @test boundary_indices(g, LowerBoundary()) == 1
+        @test boundary_indices(g, UpperBoundary()) == 81
     end
 
     @testset "refine" begin