Skip to content

Commit 79aa052

Browse files
committed
Acceptance testing files
1 parent c7447d8 commit 79aa052

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

cypress.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"baseUrl": "http://localhost:8080",
2+
"baseUrl": "http://localhost:10001",
33
"integrationFolder": "tests/e2e/integration",
44
"fileServerFolder": "demo",
55
"pluginsFile": false,

cypress/fixtures/example.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"name": "Using fixtures to represent data",
3+
"email": "[email protected]",
4+
"body": "Fixtures are a great way to mock data for responses to routes"
5+
}

tests/e2e/integration/skip-to.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
describe('index', () => {
2+
beforeEach(() => {
3+
cy.visit('/')
4+
})
5+
6+
it('Should assert that page content is correct', () => {
7+
cy.get('[data-vst="skip-to"]').should('contain', 'Skip to')
8+
})
9+
10+
it('Checks if destination is receiving focus', () => {
11+
cy.get('[data-vst="skip-to"]').focus().click()
12+
cy.focused().should('have.id', 'main')
13+
})
14+
})

0 commit comments

Comments
 (0)