NEW236595
testapi should handle a missing testapiScripts directory cleaner
https://bugs.webkit.org/show_bug.cgi?id=236595
Summary testapi should handle a missing testapiScripts directory cleaner
Keith Miller
Reported 2022-02-14 09:20:43 PST
testapi should handle a missing testapiScripts directory cleaner
Attachments
Patch (1.54 KB, patch)
2022-02-14 09:21 PST, Keith Miller
ysuzuki: review+
Keith Miller
Comment 1 2022-02-14 09:21:33 PST
Yusuke Suzuki
Comment 2 2022-02-14 09:56:22 PST
Comment on attachment 451912 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=451912&action=review r=me > Source/JavaScriptCore/API/tests/testapi.mm:2839 > + if (![resolvePathToScripts() checkResourceIsReachableAndReturnError:nil]) { > + NSLog(@"File URL to testapiScripts: %@", resolvePathToScripts()); > + checkResult(@"File URL to `testapiScripts` isn't reachable is the directory in place?", false); > + return; > + } > + How about always showing NSLog(@"File URL to testapiScripts: %@", resolvePathToScripts()); and doing, checkResult(@"File URL to `testapiScripts` isn't reachable is the directory in place?", [resolvePathToScripts() checkResourceIsReachableAndReturnError:nil]);
Keith Miller
Comment 3 2022-02-14 10:39:01 PST
Comment on attachment 451912 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=451912&action=review >> Source/JavaScriptCore/API/tests/testapi.mm:2839 >> + > > How about always showing > > NSLog(@"File URL to testapiScripts: %@", resolvePathToScripts()); > > and doing, > > checkResult(@"File URL to `testapiScripts` isn't reachable is the directory in place?", [resolvePathToScripts() checkResourceIsReachableAndReturnError:nil]); Ok, sounds good.
Keith Miller
Comment 4 2022-02-14 10:41:08 PST
Comment on attachment 451912 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=451912&action=review >>> Source/JavaScriptCore/API/tests/testapi.mm:2839 >>> + >> >> How about always showing >> >> NSLog(@"File URL to testapiScripts: %@", resolvePathToScripts()); >> >> and doing, >> >> checkResult(@"File URL to `testapiScripts` isn't reachable is the directory in place?", [resolvePathToScripts() checkResourceIsReachableAndReturnError:nil]); > > Ok, sounds good. Do you think we should return after finding the file is missing or just continue in case the test doesn't rely on that directory?
Radar WebKit Bug Importer
Comment 5 2022-02-21 09:21:18 PST
Note You need to log in before you can comment on or make changes to this bug.