@@ -8,7 +8,7 @@ function test_io(AT)
8
8
9
9
show (io, MIME (" text/plain" ), A)
10
10
seekstart (io)
11
- @test String ( take! (io)) == " 1-element $AT {Int64,1}:\n 1"
11
+ @test occursin ( Regex ( " ^ 1-element $AT {Int64,1.* }:\n 1\$ " ), String ( take! (io)))
12
12
13
13
show (io, A)
14
14
seekstart (io)
@@ -19,7 +19,7 @@ function test_io(AT)
19
19
20
20
show (io, MIME (" text/plain" ), B)
21
21
seekstart (io)
22
- @test String ( take! (io)) == " 2×2 $AT {Int64,2}:\n 1 2\n 3 4"
22
+ @test occursin ( Regex ( " ^ 2×2 $AT {Int64,2.* }:\n 1 2\n 3 4\$ " ), String ( take! (io)))
23
23
24
24
show (io, B)
25
25
seekstart (io)
@@ -29,8 +29,8 @@ function test_io(AT)
29
29
show (io, MIME (" text/plain" ), A' )
30
30
seekstart (io)
31
31
msg = String (take! (io)) # the printing of Adjoint depends on global state
32
- @test msg == " 1×1 Adjoint{Int64,$AT {Int64,1}}:\n 1" ||
33
- msg == " 1×1 LinearAlgebra.Adjoint{Int64,$AT {Int64,1}}:\n 1"
32
+ @test occursin ( Regex ( " ^ 1×1 Adjoint{Int64,$AT {Int64,1.* }}:\n 1\$ " ), msg) ||
33
+ occursin ( Regex ( " ^ 1×1 LinearAlgebra.Adjoint{Int64,$AT {Int64,1.* }}:\n 1\$ " ), msg)
34
34
end
35
35
end
36
36
end
0 commit comments