@@ -411,12 +411,15 @@ along with a summary of the test results.
411411type DefaultTestSet <:  AbstractTestSet 
412412    description:: AbstractString 
413413    results:: Vector 
414+     n_passed:: Int 
414415    anynonpass:: Bool 
415416end 
416- DefaultTestSet (desc) =  DefaultTestSet (desc, [], false )
417+ DefaultTestSet (desc) =  DefaultTestSet (desc, [], 0 ,  false )
417418
418- #  For a passing or broken result, simply store the result
419- record (ts:: DefaultTestSet , t:: Union{Pass,Broken} ) =  (push! (ts. results, t); t)
419+ #  For a broken result, simply store the result
420+ record (ts:: DefaultTestSet , t:: Broken ) =  (push! (ts. results, t); t)
421+ #  For a passed result, do not store the result since it uses a lot of memory
422+ record (ts:: DefaultTestSet , t:: Pass ) =  (ts. n_passed +=  1 ; t)
420423
421424#  For the other result types, immediately print the error message
422425#  but do not terminate. Print a backtrace.
@@ -520,10 +523,9 @@ get_alignment(ts, depth::Int) = 0
520523#  Recursive function that counts the number of test results of each
521524#  type directly in the testset, and totals across the child testsets
522525function  get_test_counts (ts:: DefaultTestSet )
523-     passes, fails, errors, broken =  0 , 0 , 0 , 0 
526+     passes, fails, errors, broken =  ts . n_passed , 0 , 0 , 0 
524527    c_passes, c_fails, c_errors, c_broken =  0 , 0 , 0 , 0 
525528    for  t in  ts. results
526-         isa (t, Pass)   &&  (passes +=  1 )
527529        isa (t, Fail)   &&  (fails  +=  1 )
528530        isa (t, Error)  &&  (errors +=  1 )
529531        isa (t, Broken) &&  (broken +=  1 )
0 commit comments