-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New user and tutorial e2e tests (#937)
* new user and tutorial e2e tests * update snapshots * removed unused tests & added tutorial flow from webpage * add tapAtPoint to the helpers
- Loading branch information
1 parent
42c3fc8
commit dbeebae
Showing
16 changed files
with
497 additions
and
318 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
'use strict'; | ||
import TestHelpers from './helpers'; | ||
|
||
describe('MetaMetrics opt-out', () => { | ||
it('should be able to opt-out of MetaMetrics', async () => { | ||
// Check that we are on the home screen | ||
await TestHelpers.checkIfVisible('home-screen'); | ||
// Check that Start Exploring CTA is visible & tap it | ||
await TestHelpers.waitAndTap('start-exploring-button'); | ||
// Check that we are on the MetaMetrics optIn screen | ||
await TestHelpers.checkIfVisible('metaMetrics-OptIn'); | ||
// Check that "No thanks" CTA is visible and tap it | ||
await TestHelpers.waitAndTap('cancel-button'); | ||
// Check that we are on the wallet screen | ||
await TestHelpers.checkIfExists('wallet-screen'); | ||
// Check that the onboarding wizard is present | ||
await TestHelpers.checkIfVisible('onboarding-wizard-step1-view'); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
'use strict'; | ||
import TestHelpers from './helpers'; | ||
|
||
describe('Onboarding wizard opt-out', () => { | ||
it('should be able to opt-out of the onboarding-wizard', async () => { | ||
// Check that we are on the home screen | ||
await TestHelpers.checkIfVisible('home-screen'); | ||
// Check that Start Exploring CTA is visible & tap it | ||
await TestHelpers.waitAndTap('start-exploring-button'); | ||
// Check that we are on the MetaMetrics optIn screen | ||
await TestHelpers.checkIfVisible('metaMetrics-OptIn'); | ||
// Check that "No thanks" CTA is visible and tap it | ||
await TestHelpers.waitAndTap('cancel-button'); | ||
// Check that we are on the wallet screen | ||
await TestHelpers.checkIfExists('wallet-screen'); | ||
// Check that the onboarding wizard is present | ||
await TestHelpers.checkIfVisible('onboarding-wizard-step1-view'); | ||
// Check that No thanks CTA is visible and tap it | ||
await TestHelpers.waitAndTap('onboarding-wizard-back-button'); | ||
// Check that the onboarding wizard is gone | ||
await TestHelpers.checkIfNotVisible('onboarding-wizard-step1-view'); | ||
// Relaunch the app | ||
await device.reloadReactNative(); | ||
// Check that we are on the Browser page | ||
await TestHelpers.checkIfVisible('browser-screen'); | ||
// Check that the wizard is not visible anymore | ||
await TestHelpers.checkIfNotVisible('onboarding-wizard-step1-view'); | ||
}); | ||
|
||
it('should tap on take a tour on browser then skip tutorial', async () => { | ||
// Check that we are on the Browser page | ||
await TestHelpers.checkIfVisible('browser-screen'); | ||
// Scroll to bottom of browser view | ||
await TestHelpers.swipe('browser-screen', 'up'); | ||
// Tap on the Take a tour box | ||
await TestHelpers.tapAtPoint('browser-screen', { x: 215, y: 555 }); | ||
// Check that we are on the wallet screen | ||
await TestHelpers.checkIfExists('wallet-screen'); | ||
// Check that the onboarding wizard is present | ||
await TestHelpers.checkIfVisible('onboarding-wizard-step1-view'); | ||
// Check that Take the tour CTA is visible and tap it | ||
await TestHelpers.waitAndTap('onboarding-wizard-next-button'); | ||
// Tap on Skip Tutorial | ||
await TestHelpers.tapByText('Skip Tutorial'); | ||
// Check that the wizard is not visible anymore | ||
await TestHelpers.checkIfNotVisible('onboarding-wizard-step1-view'); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
'use strict'; | ||
import TestHelpers from './helpers'; | ||
|
||
describe('Start Exploring', () => { | ||
it('should show the home screen', async () => { | ||
// Check that we are on the home screen | ||
await TestHelpers.checkIfVisible('home-screen'); | ||
}); | ||
|
||
it('should allow you to create a new wallet', async () => { | ||
// Check that Start Exploring CTA is visible & tap it | ||
await TestHelpers.waitAndTap('start-exploring-button'); | ||
// Check that we are on the metametrics optIn screen | ||
await TestHelpers.checkIfVisible('metaMetrics-OptIn'); | ||
}); | ||
|
||
it('should tap I Agree and land on the wallet view with tutorial open', async () => { | ||
// Check that I Agree CTA is visible and tap it | ||
await TestHelpers.waitAndTap('agree-button'); | ||
// Check that we are on the wallet screen | ||
await TestHelpers.checkIfExists('wallet-screen'); | ||
// Check that the onboarding wizard is present | ||
await TestHelpers.checkIfVisible('onboarding-wizard-step1-view'); | ||
}); | ||
|
||
it('should go through the onboarding wizard flow', async () => { | ||
// Check that Take the tour CTA is visible and tap it | ||
await TestHelpers.waitAndTap('onboarding-wizard-next-button'); | ||
// Check that Got it! CTA is visible and tap it | ||
await TestHelpers.tapByText('Got it!'); | ||
// Check that Got it! CTA is visible and tap it | ||
await TestHelpers.tapByText('Got it!'); | ||
// Check that Got it! CTA is visible and tap it | ||
await TestHelpers.tapByText('Got it!'); | ||
// Check that Got it! CTA is visible and tap it | ||
await TestHelpers.tapByText('Got it!'); | ||
// Check that Got it! CTA is visible and tap it | ||
await TestHelpers.tapByText('Got it!'); | ||
// Check that we are on the Browser page | ||
await TestHelpers.checkIfVisible('browser-screen'); | ||
}); | ||
}); |
Oops, something went wrong.