-
-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Adjusted return users flow to navigate to timeline
- Loading branch information
Showing
6 changed files
with
33 additions
and
16,147 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,32 @@ | ||
/// <reference types="cypress" /> | ||
import {CHANGE_REMOTE_PEER_ID} from '../../../src/store/action-types'; | ||
|
||
context('HomePage', () => { | ||
beforeEach(() => { | ||
cy.visit('/') | ||
}) | ||
beforeEach(() => { | ||
cy.visit('/') | ||
}) | ||
|
||
it('Loads title and subtitle', () => { | ||
cy.get('.v-list-item__subtitle') | ||
.should('contain.text', 'Cozy at Home - via Ambient Intelligence') | ||
}) | ||
|
||
it('Loads firsttime installation button', () => { | ||
cy.get('#btn-timeline > .v-btn__content') | ||
.should('contain.text', 'Continue Setup') | ||
.click() | ||
}) | ||
|
||
it('Ensures returning users are taken directly to timeline', () => { | ||
cy.window().should('have.property', '__store__') | ||
cy.window().then(win => { | ||
win.__store__.dispatch(CHANGE_REMOTE_PEER_ID, '917d5f0a-6469-4d33-b5c2-efd858118b74') | ||
cy.wait(1000) | ||
|
||
it('Loads title and subtitle', () => { | ||
cy.get('.v-list-item__subtitle') | ||
.should('contain.text', 'Cozy at Home - via Ambient Intelligence') | ||
}) | ||
// reload to use new values for testing | ||
cy.reload() | ||
|
||
it('Loads firsttime installation button', () => { | ||
cy.get('#btn-timeline > .v-btn__content') | ||
.should('contain.text', 'Continue Setup') | ||
.click() | ||
}) | ||
cy.url().should('include', '/timeline') | ||
}) | ||
}) | ||
}) |
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 |
---|---|---|
|
@@ -24,3 +24,7 @@ new Vue({ | |
vuetify, | ||
render: h => h(App) | ||
}).$mount('#app') | ||
|
||
if (window.Cypress) { | ||
window.__store__ = store | ||
} |
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
Oops, something went wrong.