From dad5e79df3ecea5dd3ae991d2688cc2c652881c9 Mon Sep 17 00:00:00 2001 From: Vladimir Enchev Date: Fri, 13 Jan 2017 14:38:19 +0200 Subject: [PATCH] test moved to ui-tests-app (#3485) Should be tested with no connection --- .../ui-tests-app/web-view/web-view-error.ts | 3 +++ .../ui-tests-app/web-view/web-view-error.xml | 3 +++ tests/app/ui/web-view/web-view-tests.ts | 21 ------------------- 3 files changed, 6 insertions(+), 21 deletions(-) create mode 100644 apps/app/ui-tests-app/web-view/web-view-error.ts create mode 100644 apps/app/ui-tests-app/web-view/web-view-error.xml diff --git a/apps/app/ui-tests-app/web-view/web-view-error.ts b/apps/app/ui-tests-app/web-view/web-view-error.ts new file mode 100644 index 000000000..ef7d09dcd --- /dev/null +++ b/apps/app/ui-tests-app/web-view/web-view-error.ts @@ -0,0 +1,3 @@ +export function onLoadFinished(args) { + console.log("### onLoadFinished with error: " + args.error); +} diff --git a/apps/app/ui-tests-app/web-view/web-view-error.xml b/apps/app/ui-tests-app/web-view/web-view-error.xml new file mode 100644 index 000000000..a445f2592 --- /dev/null +++ b/apps/app/ui-tests-app/web-view/web-view-error.xml @@ -0,0 +1,3 @@ + + + diff --git a/tests/app/ui/web-view/web-view-tests.ts b/tests/app/ui/web-view/web-view-tests.ts index 89524d3b0..b94cb11c0 100644 --- a/tests/app/ui/web-view/web-view-tests.ts +++ b/tests/app/ui/web-view/web-view-tests.ts @@ -127,27 +127,6 @@ export class WebViewTest extends testModule.UITest { // << webview-string } - public testLoadInvalidUrl(done) { - let webView = this.testView; - let actualError; - - webView.on(webViewModule.WebView.loadFinishedEvent, function (args: webViewModule.LoadEventData) { - if (actualError) { - // Android call this twice -- the second time args.error is undefined. - return; - } - actualError = args.error; - try { - TKUnit.assert(actualError !== undefined, "There should be an error."); - done(null); - } - catch (e) { - done(e); - } - }); - webView.src = "kofti://mnogokofti"; - } - public testLoadUpperCaseSrc(done) { let webView = this.testView; let targetSrc = "HTTPS://github.com/";