From 32bb09bcb9dd5f9db86967128f7d0fe154fe9922 Mon Sep 17 00:00:00 2001 From: kumavis Date: Fri, 30 Mar 2018 13:52:42 -0700 Subject: [PATCH] test - e2e - set network to localhost --- test/e2e/metamask.spec.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/test/e2e/metamask.spec.js b/test/e2e/metamask.spec.js index ff5bdb51b..20e23e2ea 100644 --- a/test/e2e/metamask.spec.js +++ b/test/e2e/metamask.spec.js @@ -38,6 +38,8 @@ describe('Metamask popup page', function () { const tabs = await driver.getAllWindowHandles() await driver.switchTo().window(tabs[0]) await delay(300) + await setProviderType('localhost') + await delay(300) }) it('should match title', async () => { @@ -124,6 +126,10 @@ describe('Metamask popup page', function () { }) }) + async function setProviderType(type) { + await driver.executeScript('window.metamask.setProviderType(arguments[0])', type) + } + async function verboseReportOnFailure(test) { const artifactDir = `./test-artifacts/${test.title}` const filepathBase = `${artifactDir}/test-failure`