@@ -1848,13 +1848,20 @@ EVENT and ARG are described in `buttercup-reporter'."
1848
1848
(when (buttercup--reporter-batch-preprint-spec-p arg)
1849
1849
(buttercup--print " %s" (buttercup--indented-description arg))))
1850
1850
(`spec-done
1851
+ ; ; When printing has been held back but we will print the
1852
+ ; ; result of this spec, print the all of the containing suite
1853
+ ; ; descriptions that have been held back
1851
1854
(when (and buttercup-reporter-batch-quiet-statuses
1852
1855
(not (buttercup-reporter-batch--quiet-spec-p arg)))
1853
1856
(dolist (suite (nreverse buttercup-reporter-batch--suite-stack))
1854
1857
(buttercup--print " %s\n " (buttercup--indented-description suite)))
1855
1858
(setq buttercup-reporter-batch--suite-stack nil )
1856
- (buttercup--print " %s" (buttercup--indented-description arg)))
1859
+ ; ; Also print the spec description unless it should not be preprinted
1860
+ (unless (buttercup--reporter-batch-preprint-spec-p arg)
1861
+ (buttercup--print " %s" (buttercup--indented-description arg))))
1857
1862
1863
+ ; ; print the result of the spec. This should erase any
1864
+ ; ; non-colored spec text.
1858
1865
(unless (buttercup-reporter-batch--quiet-spec-p arg)
1859
1866
(buttercup-reporter-batch--print-spec-done-line arg buttercup-color))
1860
1867
@@ -1914,11 +1921,14 @@ Finally print the elapsed time for SPEC."
1914
1921
(`failed 'red )
1915
1922
(`skipped nil ))))
1916
1923
(when color
1917
- ; ; Carriage returns (\r) should not be colorized. It would mess
1918
- ; ; up color handling in Emacs compilation buffers using
1919
- ; ; `ansi-color-apply-on-region' in `compilation-filter-hook' .
1920
- (buttercup--print " %s%s"
1921
- (if (buttercup--reporter-batch-preprint-spec-p spec) " \r " " " )
1924
+ ; ; Clear the line if
1925
+ (when (or buttercup-reporter-batch-quiet-statuses
1926
+ (buttercup--reporter-batch-preprint-spec-p spec))
1927
+ ; ; Carriage returns (\r) should not be colorized. It would mess
1928
+ ; ; up color handling in Emacs compilation buffers using
1929
+ ; ; `ansi-color-apply-on-region' in `compilation-filter-hook' .
1930
+ (buttercup--print " \r " ))
1931
+ (buttercup--print " %s"
1922
1932
(buttercup-colorize
1923
1933
(buttercup--indented-description spec) color)))
1924
1934
(unless (eq 'passed status)
0 commit comments