Fix the output of the CDN test. (#148730)
This test was outputting the "success" string multiple times, which is probably causing the harness to kill the app halfway through its cycle. I suspect this is causing some of the flakiness we've seen of this test. Instead, we should just output the string at the very end of the test, right before the app is done.
This commit is contained in:
@@ -66,7 +66,7 @@ const List<StackFrame> expectedDebugStackFrames = <StackFrame>[
|
||||
/// Tests that we do not crash while parsing Web stack traces.
|
||||
///
|
||||
/// This test is run in debug, profile, and release modes.
|
||||
void main() {
|
||||
void main() async {
|
||||
final StringBuffer output = StringBuffer();
|
||||
try {
|
||||
try {
|
||||
@@ -97,14 +97,14 @@ void main() {
|
||||
output.writeln(unexpectedStackTrace);
|
||||
output.writeln('--- TEST FAILED ---');
|
||||
}
|
||||
print(output);
|
||||
web.window.fetch(
|
||||
await web.window.fetch(
|
||||
'/test-result'.toJS,
|
||||
web.RequestInit(
|
||||
method: 'POST',
|
||||
body: '$output'.toJS,
|
||||
)
|
||||
);
|
||||
).toDart;
|
||||
print(output);
|
||||
}
|
||||
|
||||
@noInline
|
||||
|
||||
Reference in New Issue
Block a user