-
Notifications
You must be signed in to change notification settings - Fork 178
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test(pd): typescript and test pattern
- Loading branch information
Showing
24 changed files
with
793 additions
and
434 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 |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import { | ||
Actions, | ||
Verifications, | ||
runCreateTest, | ||
verifyCreateProtocolPage, | ||
} from '../support/createNew' | ||
import { UniversalActions } from '../support/universalActions' | ||
|
||
describe('The Redesigned Create Protocol Landing Page', () => { | ||
beforeEach(() => { | ||
cy.visit('/') | ||
}) | ||
|
||
it('content and step 1 flow works', () => { | ||
cy.clickCreateNew() | ||
cy.verifyCreateNewHeader() | ||
verifyCreateProtocolPage() | ||
const steps: Array<Actions | Verifications | UniversalActions> = [ | ||
Verifications.OnStep1, | ||
Verifications.FlexSelected, | ||
UniversalActions.Snapshot, | ||
Actions.SelectOT2, | ||
Verifications.OT2Selected, | ||
UniversalActions.Snapshot, | ||
Actions.SelectFlex, | ||
Verifications.FlexSelected, | ||
UniversalActions.Snapshot, | ||
Actions.Confirm, | ||
Verifications.OnStep2, | ||
Verifications.NinetySixChannel, | ||
UniversalActions.Snapshot, | ||
Actions.GoBack, | ||
Verifications.OnStep1, | ||
Actions.SelectOT2, | ||
Actions.Confirm, | ||
Verifications.OnStep2, | ||
Verifications.NotNinetySixChannel, | ||
UniversalActions.Snapshot, | ||
] | ||
|
||
runCreateTest(steps) | ||
}) | ||
}) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
describe('The Home Page', () => { | ||
beforeEach(() => { | ||
cy.visit('/') | ||
}) | ||
|
||
it('successfully loads', () => { | ||
// JTM20241109 | ||
// Normally we want to read our test and understand the validations, | ||
// but I forsee wanting to be able to call these functions from multiple | ||
// places so we will abstract it | ||
cy.verifyFullHeader() | ||
cy.verifyHomePage() | ||
}) | ||
}) |
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,14 @@ | ||
import { TestFilePath, getTestFile } from '../support/testFiles' | ||
import { verifyOldProtocolModal } from '../support/import' | ||
|
||
describe('The Import Page', () => { | ||
beforeEach(() => { | ||
cy.visit('/') | ||
}) | ||
|
||
it('successfully loads', () => { | ||
const protocol = getTestFile(TestFilePath.DoItAllV8) | ||
cy.importProtocol(protocol.path) | ||
verifyOldProtocolModal() | ||
}) | ||
}) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.