forked from ambianic/ambianic-ui
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
47 additions
and
28 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,48 @@ | ||
/// <reference types="cypress" /> | ||
|
||
context('Check Navbar Items', () => { | ||
before(() => { | ||
cy.visit('http://localhost:8080') | ||
cy.get('[data-cy=timeline]').click() | ||
}) | ||
before(() => { | ||
cy.visit('http://localhost:8080') | ||
cy.get('[data-cy=timeline]').click() | ||
}) | ||
|
||
it('Should have a search bar', () => { | ||
cy.get('[data-cy=container').find("#searchbar") | ||
}) | ||
it('Should have a search bar', () => { | ||
cy.get('[data-cy=container').find("#searchbar") | ||
}) | ||
|
||
it('Should be a download off button', () => { | ||
const t = cy.get('[data-cy=download-off]') | ||
expect(t).to.exist | ||
}) | ||
it('Should be a download off button', () => { | ||
const t = cy.get('[data-cy=download-off]') | ||
expect(t).to.exist | ||
}) | ||
|
||
it('Should be a heart button', () => { | ||
const t = cy.get('[data-cy=heart]') | ||
expect(t).to.exist | ||
}) | ||
it('Should be a heart button', () => { | ||
const t = cy.get('[data-cy=heart]') | ||
expect(t).to.exist | ||
}) | ||
|
||
it('Should be a bell button', () => { | ||
const t = cy.get('[data-cy=bell]') | ||
expect(t).to.exist | ||
}) | ||
it('Should be a bell button', () => { | ||
const t = cy.get('[data-cy=bell]') | ||
expect(t).to.exist | ||
}) | ||
|
||
it('Should be an about button', () => { | ||
const t = cy.get('[data-cy=about]') | ||
expect(t).to.exist | ||
}) | ||
it('Should be an about button', () => { | ||
const t = cy.get('[data-cy=about]') | ||
expect(t).to.exist | ||
}) | ||
|
||
it('Should have a five links', () => { | ||
cy.get('[data-cy=drawer]').then(($result) => { | ||
assert.equal($result.children().children()[0].childElementCount,5,'Five links in the drawer') | ||
}) | ||
it('Should have a five links', () => { | ||
cy.get('[data-cy=drawer]').then(($result) => { | ||
assert.equal($result.children().children()[0].childElementCount,5,'Five links in the drawer') | ||
}) | ||
}) | ||
|
||
it('Should have a clickable timeline icon', () => { | ||
const icon = cy.get('[data-cy=timeline-icon]') | ||
|
||
icon.should("be.visible") | ||
|
||
icon.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