Index: third_party/WebKit/LayoutTests/http/tests/inspector/persistence/persistence-go-to-file-dialog.html |
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/persistence/persistence-go-to-file-dialog.html b/third_party/WebKit/LayoutTests/http/tests/inspector/persistence/persistence-go-to-file-dialog.html |
index 0ed8e24e4b48d02e5619982f7775babc165cdde0..5880be05f90c6e36e673832224c8ec13cb407e9d 100644 |
--- a/third_party/WebKit/LayoutTests/http/tests/inspector/persistence/persistence-go-to-file-dialog.html |
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/persistence/persistence-go-to-file-dialog.html |
@@ -25,8 +25,7 @@ function test() |
function goToSourceDialogBeforeBinding(next) |
{ |
- dumpGoToSourceDialog(); |
- next(); |
+ dumpGoToSourceDialog(next); |
}, |
function addFileSystemMapping(next) |
@@ -37,21 +36,22 @@ function test() |
function goToSourceAfterBinding(next) |
{ |
- dumpGoToSourceDialog(); |
- next(); |
+ dumpGoToSourceDialog(next); |
}, |
]); |
- function dumpGoToSourceDialog() |
+ function dumpGoToSourceDialog(next) |
{ |
- UI.panels.sources._sourcesView.showOpenResourceDialog(); |
- var dialog = Sources.OpenResourceDialog._instanceForTest; |
- var keys = []; |
- for (var i = 0; i < dialog.itemCount(); ++i) |
- keys.push(dialog.itemKeyAt(i)); |
- keys.sort(); |
- InspectorTest.addResult(keys.join("\n")); |
- UI.Dialog._instance.hide(); |
+ QuickOpen.QuickOpen.show(''); |
+ InspectorTest.addSnifferPromise(QuickOpen.QuickOpen.prototype, '_providerLoadedForTest').then(provider => { |
+ var keys = []; |
+ for (var i = 0; i < provider.itemCount(); ++i) |
+ keys.push(provider.itemKeyAt(i)); |
+ keys.sort(); |
+ InspectorTest.addResult(keys.join("\n")); |
+ UI.Dialog._instance.hide(); |
+ next(); |
+ }); |
} |
}; |
</script> |