Skip to content

Commit 5ce7945

Browse files
committed
Changes from JuliaTesting#55 and new test
1 parent d8d83d4 commit 5ce7945

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

src/remotetestset.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@ Test.record(ts::RemoteTestSet, t::AbstractTestSet) = Test.record(ts.ts, t)
3232

3333
# This is the single method that needs changing
3434
function Test.finish(ts::RemoteTestSet; print_results::Bool=Test.TESTSET_PRINT_ENABLE[])
35-
if Test.get_testset_depth() != 0
36-
throw(ErrorException("RemoteTestSet should only ever be a top-level TestSet"))
37-
end
35+
# This testset is just a placeholder,
36+
# so it must be the top-most
37+
@assert Test.get_testset_depth() == 0
3838

39-
# Otherwise, just return the testset so it is returned from the @testset macro
39+
# There should only ever be one child testset
4040
return only(ts.ts.results)
4141
end
4242

test/basicts.jl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
@testset "basic in testset" begin
2+
@test true
3+
end

0 commit comments

Comments
 (0)