@@ -12,6 +12,7 @@ import { ITestRunner, ITestDebugLauncher, IUnitTestSocketServer, LaunchOptions,
1212import { TEST_OUTPUT_CHANNEL } from '../../constants' ;
1313import { getTestCaseNodes } from '../common/testItemUtilities' ;
1414import { ITestRun , ITestsRunner , TestData , TestRunInstanceOptions , TestRunOptions } from '../common/types' ;
15+ import { fixLogLines } from '../common/utils' ;
1516import { getTestRunArgs } from './arguments' ;
1617
1718interface ITestData {
@@ -102,7 +103,7 @@ export class UnittestRunner implements ITestsRunner {
102103 if ( data . outcome === 'passed' || data . outcome === 'failed-expected' ) {
103104 const text = `${ rawTestCase . rawId } Passed\r\n` ;
104105 runInstance . passed ( testCase ) ;
105- runInstance . appendOutput ( text ) ;
106+ runInstance . appendOutput ( fixLogLines ( text ) ) ;
106107 counts . passed += 1 ;
107108 } else if ( data . outcome === 'failed' || data . outcome === 'passed-unexpected' ) {
108109 const traceback = data . traceback
@@ -116,7 +117,7 @@ export class UnittestRunner implements ITestsRunner {
116117 }
117118
118119 runInstance . failed ( testCase , message ) ;
119- runInstance . appendOutput ( text ) ;
120+ runInstance . appendOutput ( fixLogLines ( text ) ) ;
120121 counts . failed += 1 ;
121122 if ( failFast ) {
122123 stopTesting = true ;
@@ -133,7 +134,7 @@ export class UnittestRunner implements ITestsRunner {
133134 }
134135
135136 runInstance . errored ( testCase , message ) ;
136- runInstance . appendOutput ( text ) ;
137+ runInstance . appendOutput ( fixLogLines ( text ) ) ;
137138 counts . errored += 1 ;
138139 if ( failFast ) {
139140 stopTesting = true ;
@@ -144,11 +145,11 @@ export class UnittestRunner implements ITestsRunner {
144145 : '' ;
145146 const text = `${ rawTestCase . rawId } Skipped: ${ data . message } \r\n${ traceback } \r\n` ;
146147 runInstance . skipped ( testCase ) ;
147- runInstance . appendOutput ( text ) ;
148+ runInstance . appendOutput ( fixLogLines ( text ) ) ;
148149 counts . skipped += 1 ;
149150 } else {
150151 const text = `Unknown outcome type for test ${ rawTestCase . rawId } : ${ data . outcome } ` ;
151- runInstance . appendOutput ( text ) ;
152+ runInstance . appendOutput ( fixLogLines ( text ) ) ;
152153 const message = new TestMessage ( text ) ;
153154 if ( testCase . uri && testCase . range ) {
154155 message . location = new Location ( testCase . uri , testCase . range ) ;
0 commit comments