Skip to content

Commit

Permalink
Test: Fix indenting on verbose no-failure report (#43251)
Browse files Browse the repository at this point in the history
  • Loading branch information
IanButterworth committed Nov 29, 2021
1 parent ddca0a8 commit 6bea8e3
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions stdlib/Test/src/Test.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1114,8 +1114,8 @@ end
function get_alignment(ts::DefaultTestSet, depth::Int)
# The minimum width at this depth is
ts_width = 2*depth + length(ts.description)
# If all passing, no need to look at children
!ts.anynonpass && return ts_width
# If not verbose and all passing, no need to look at children
!ts.verbose && !ts.anynonpass && return ts_width
# Return the maximum of this width and the minimum width
# for all children (if they exist)
isempty(ts.results) && return ts_width
Expand Down
24 changes: 12 additions & 12 deletions stdlib/Test/test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1079,17 +1079,17 @@ end

@testset "verbose option" begin
expected = """
Test Summary: | Pass Total
Parent | 9 9
Child 1 | 3 3
Child 1.1 | 1 1
Child 1.2 | 1 1
Child 1.3 | 1 1
Child 2 | 3 3
Child 3 | 3 3
Child 3.1 | 1 1
Child 3.2 | 1 1
Child 3.3 | 1 1
Test Summary: | Pass Total
Parent | 9 9
Child 1 | 3 3
Child 1.1 (long name) | 1 1
Child 1.2 | 1 1
Child 1.3 | 1 1
Child 2 | 3 3
Child 3 | 3 3
Child 3.1 | 1 1
Child 3.2 | 1 1
Child 3.3 | 1 1
"""

mktemp() do f, _
Expand All @@ -1099,7 +1099,7 @@ end
@testset "Parent" verbose = true begin
@testset "Child 1" verbose = true begin
@testset "Child 1.1" begin
@testset "Child 1.1 (long name)" begin
@test 1 == 1
end
Expand Down

2 comments on commit 6bea8e3

@nanosoldier
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Executing the daily package evaluation, I will reply here when finished:

@nanosoldier runtests(ALL, isdaily = true)

@nanosoldier
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your package evaluation job has completed - possible new issues were detected. A full report can be found here.

Please sign in to comment.