File tree 1 file changed +8
-1
lines changed
1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -654,8 +654,13 @@ final class TestRunner {
654
654
if let results = results {
655
655
printToWidth ( String ( describing: results. samples. count) , width: 10 , justify: . right)
656
656
if results. samples. count > 0 {
657
- let min = results. samples. sorted ( ) . first!
657
+ let sorted = results. samples. sorted ( )
658
+ let min = sorted. first!
659
+ let max = sorted. last!
660
+ let median = sorted [ sorted. count / 2 ]
658
661
printDoubleToWidth ( min, width: 10 )
662
+ printDoubleToWidth ( median, width: 10 )
663
+ printDoubleToWidth ( max, width: 10 )
659
664
}
660
665
}
661
666
print ( )
@@ -668,6 +673,8 @@ final class TestRunner {
668
673
printToWidth ( " TEST " , width: c. testNameLength, justify: . left)
669
674
printToWidth ( " SAMPLES " , width: 10 , justify: . right)
670
675
printToWidth ( " MIN " , width: 10 , justify: . right)
676
+ printToWidth ( " MEDIAN " , width: 10 , justify: . right)
677
+ printToWidth ( " MAX " , width: 10 , justify: . right)
671
678
print ( )
672
679
}
673
680
You can’t perform that action at this time.
0 commit comments