File tree Expand file tree Collapse file tree 2 files changed +12
-6
lines changed Expand file tree Collapse file tree 2 files changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -116,7 +116,7 @@ export default defineConfig({
116
116
type : 'midscene_web_dump' ,
117
117
playwright_test_description : item . data . groupDescription ,
118
118
playwright_test_id : `id-${ index } ` ,
119
- playwright_test_title : 'test open new tab' ,
119
+ playwright_test_title : item . data . groupName ,
120
120
playwright_test_status : 'passed' ,
121
121
playwright_test_duration : Math . round (
122
122
Math . random ( ) * 100000 ,
Original file line number Diff line number Diff line change 1
1
import './sidebar.less' ;
2
2
import { useAllCurrentTasks , useExecutionDump } from '@/components/store' ;
3
- import { PauseOutlined } from '@ant-design/icons' ;
4
3
import type { ExecutionTask , ExecutionTaskInsightLocate } from '@midscene/core' ;
5
4
import {
6
5
type AnimationScript ,
@@ -66,10 +65,17 @@ const SideItem = (props: {
66
65
statusText = timeCostStrElement ( task . timing . cost ) ;
67
66
}
68
67
69
- const statusIcon =
70
- task . status === 'finished' && task . error
71
- ? iconForStatus ( 'finishedWithWarning' )
72
- : iconForStatus ( task . status ) ;
68
+ const statusIcon = ( ( ) => {
69
+ const isFinished = task . status === 'finished' ;
70
+ const isAssertFailed = isFinished && task . output === false ;
71
+ const hasError = isFinished && ( task . error || task . errorMessage ) ;
72
+
73
+ if ( isAssertFailed ) return iconForStatus ( 'failed' ) ;
74
+
75
+ if ( hasError ) return iconForStatus ( 'finishedWithWarning' ) ;
76
+
77
+ return iconForStatus ( task . status ) ;
78
+ } ) ( ) ;
73
79
74
80
const titleTextIcon =
75
81
task . type === 'Planning' ? (
You can’t perform that action at this time.
0 commit comments