(reset)
| 182 | } |
| 183 | |
| 184 | flush(reset) { |
| 185 | let didLog = false; |
| 186 | if (this._lastPrefix != null) { |
| 187 | if (this._prefixCount === 1 && this._lastPrefixHeader == null) { |
| 188 | this.log(escapeColor(this._lastLine)); |
| 189 | didLog = true; |
| 190 | } else if (this._prefixCount > 0) { |
| 191 | if (this._lastPrefixHeader !== this._lastPrefix) { |
| 192 | this.log(`<cyan>${ escapeColor(this._lastPrefix) }:`); |
| 193 | this._lastPrefixHeader = this._lastPrefix; |
| 194 | } |
| 195 | this.log(` - ${ this._prefixCount } tests passed (prefix coalesced)`); |
| 196 | didLog = true; |
| 197 | } |
| 198 | } |
| 199 | |
| 200 | if (reset) { |
| 201 | this._lastPrefixHeader = null; |
| 202 | this._lastPrefix = null; |
| 203 | } |
| 204 | |
| 205 | this._prefixCount = 0; |
| 206 | |
| 207 | return didLog; |
| 208 | } |
| 209 | |
| 210 | increaseIndent() { this._indents++; } |
| 211 |
no test coverage detected