From 23e8c061f61d581403dc8a4e12ae7165bf1d7a7f Mon Sep 17 00:00:00 2001 From: ChrisRackauckas-Claude Date: Sun, 17 May 2026 18:42:45 -0400 Subject: [PATCH] Apply Runic formatting to mooncake.jl and named_array_partition_tests.jl Fixes the FormatCheck workflow on master. Two whitespace-only fixes: - test/mooncake.jl: multi-line `@test` continuation indent - test/named_array_partition_tests.jl: drop extra horizontal alignment spaces in `@test x[...] isa Vector{...}` lines Co-Authored-By: Chris Rackauckas --- test/mooncake.jl | 2 +- test/named_array_partition_tests.jl | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/test/mooncake.jl b/test/mooncake.jl index 6a0ff28e..ef27e802 100644 --- a/test/mooncake.jl +++ b/test/mooncake.jl @@ -14,7 +14,7 @@ using RecursiveArrayTools, Mooncake, Test @testset "ArrayPartition increment_and_get_rdata!" begin @test Base.get_extension(RecursiveArrayTools, :RecursiveArrayToolsMooncakeExt) !== - nothing + nothing # Tangent produced by an upstream ChainRule. t = ArrayPartition([1.0, 2.0], [3.0, 4.0]) diff --git a/test/named_array_partition_tests.jl b/test/named_array_partition_tests.jl index 1cc9f952..2f219ed2 100644 --- a/test/named_array_partition_tests.jl +++ b/test/named_array_partition_tests.jl @@ -58,21 +58,21 @@ end @test x[[1, 2]] == [1.0, 1.0] @test x[[1, 4]] == [1.0, 2.0] - @test x[1:2] isa Vector{Float64} - @test x[1:end] isa Vector{Float64} + @test x[1:2] isa Vector{Float64} + @test x[1:end] isa Vector{Float64} @test x[[1, 4]] isa Vector{Float64} # Inferred return types: Vector, not Union - @test (@inferred x[1:2]) isa Vector{Float64} - @test (@inferred x[1:length(x)]) isa Vector{Float64} - @test (@inferred x[[1, 4]]) isa Vector{Float64} + @test (@inferred x[1:2]) isa Vector{Float64} + @test (@inferred x[1:length(x)]) isa Vector{Float64} + @test (@inferred x[[1, 4]]) isa Vector{Float64} # `similar` with a non-matching dims falls back to the backing array; # with matching dims keeps the NamedArrayPartition wrapper. @test similar(x, Float64, (2,)) isa Vector{Float64} - @test similar(x, (2,)) isa Vector{Float64} + @test similar(x, (2,)) isa Vector{Float64} @test similar(x, Float64, size(x)) isa NamedArrayPartition - @test similar(x, size(x)) isa NamedArrayPartition + @test similar(x, size(x)) isa NamedArrayPartition # Scalar indexing untouched and type-stable @test x[1] == 1.0