mirror of
https://github.com/dart-lang/sdk
synced 2024-09-15 23:09:48 +00:00
[dds] Fix sse_smoke_test on Windows
Cq-Include-Trybots: luci.dart.try:pkg-win-release-try Change-Id: I8993ee16a23bfbaeffaf48f6ef5906a4e90f11fe Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/322703 Auto-Submit: Alexander Thomas <athom@google.com> Reviewed-by: Ben Konyi <bkonyi@google.com> Commit-Queue: Ben Konyi <bkonyi@google.com>
This commit is contained in:
parent
e2971da563
commit
d12904f278
|
@ -29,10 +29,14 @@ void main() {
|
|||
late WebDriver webdriver;
|
||||
|
||||
setUpAll(() async {
|
||||
final chromedriverUri = Platform.script.resolveUri(
|
||||
Uri.parse('../../../third_party/webdriver/chrome/chromedriver'));
|
||||
var chromedriverPath = '../../../third_party/webdriver/chrome/chromedriver';
|
||||
if (Platform.isWindows) {
|
||||
chromedriverPath = '$chromedriverPath.exe';
|
||||
}
|
||||
final chromedriverUri =
|
||||
Platform.script.resolveUri(Uri.parse(chromedriverPath));
|
||||
try {
|
||||
chromeDriver = await Process.start(chromedriverUri.path, [
|
||||
chromeDriver = await Process.start(chromedriverUri.toFilePath(), [
|
||||
'--port=4444',
|
||||
'--url-base=wd/hub',
|
||||
]);
|
||||
|
@ -54,7 +58,7 @@ void main() {
|
|||
final cascade = shelf.Cascade()
|
||||
.add(handler.handler)
|
||||
.add(_faviconHandler)
|
||||
.add(createStaticHandler(Platform.script.resolve('web').path,
|
||||
.add(createStaticHandler(Platform.script.resolve('web').toFilePath(),
|
||||
listDirectories: true, defaultDocument: 'index.html'));
|
||||
|
||||
server = await io.serve(cascade.handler, 'localhost', 0);
|
||||
|
|
Loading…
Reference in a new issue