File tree Expand file tree Collapse file tree 1 file changed +11
-9
lines changed
src/tests/tracing/eventcounter Expand file tree Collapse file tree 1 file changed +11
-9
lines changed Original file line number Diff line number Diff line change @@ -104,17 +104,19 @@ public static int TestEntryPoint()
104
104
// Create an EventListener.
105
105
using ( RuntimeCounterListener myListener = new RuntimeCounterListener ( ) )
106
106
{
107
- Thread . Sleep ( 60000 ) ;
108
- if ( myListener . Verify ( ) )
107
+ // Wait max 60 seconds
108
+ for ( int i = 0 ; i < 60 ; i ++ )
109
109
{
110
- Console . WriteLine ( "Test passed" ) ;
111
- return 100 ;
112
- }
113
- else
114
- {
115
- Console . WriteLine ( $ "Test Failed - did not see one or more of the expected runtime counters.") ;
116
- return 1 ;
110
+ Thread . Sleep ( 1000 ) ;
111
+ if ( myListener . Verify ( ) )
112
+ {
113
+ Console . WriteLine ( "Test passed" ) ;
114
+ return 100 ;
115
+ }
117
116
}
117
+
118
+ Console . WriteLine ( $ "Test Failed - did not see one or more of the expected runtime counters.") ;
119
+ return 1 ;
118
120
}
119
121
}
120
122
}
You can’t perform that action at this time.
0 commit comments