Skip to content

Commit 27eb721

Browse files
authored
Update LinearAlgebra QR tests so that MKL.jl tests pass on the LinearAlgebra test suite. (#43585)
1 parent ab4e036 commit 27eb721

File tree

1 file changed

+7
-6
lines changed
  • stdlib/LinearAlgebra/test

1 file changed

+7
-6
lines changed

stdlib/LinearAlgebra/test/qr.jl

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -432,21 +432,22 @@ end
432432
@test eltype(qrnonblas.factors) == eltype(qrnonblas.τ) == ComplexF16
433433
end
434434

435+
# We use approximate equals to get MKL.jl tests to pass.
435436
@testset "optimized getindex for an AbstractQ" begin
436437
for T in [Float64, ComplexF64]
437438
Q = qr(rand(T, 4, 4))
438439
Q2 = Q.Q
439440
M = Matrix(Q2)
440441
for j in axes(M, 2)
441-
@test Q2[:, j] == M[:, j]
442+
@test Q2[:, j] M[:, j]
442443
for i in axes(M, 1)
443-
@test Q2[i, :] == M[i, :]
444-
@test Q2[i, j] == M[i, j]
444+
@test Q2[i, :] M[i, :]
445+
@test Q2[i, j] M[i, j]
445446
end
446447
end
447-
@test Q2[:] == M[:]
448-
@test Q2[:, :] == M[:, :]
449-
@test Q2[:, :, :] == M[:, :, :]
448+
@test Q2[:] M[:]
449+
@test Q2[:, :] M[:, :]
450+
@test Q2[:, :, :] M[:, :, :]
450451
end
451452
end
452453

0 commit comments

Comments
 (0)