mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-12-23 17:04:18 +00:00
28600d6508
* Change copyright year from 2020 to 2021 Signed-off-by: Tilman Vatteroth <tilman.vatteroth@tu-dortmund.de> * Change copyright year in jetbrains copyright template Signed-off-by: Tilman Vatteroth <tilman.vatteroth@tu-dortmund.de>
54 lines
1.2 KiB
TypeScript
54 lines
1.2 KiB
TypeScript
/*
|
|
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
|
*
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
*/
|
|
|
|
/* eslint-disable @typescript-eslint/no-unsafe-call */
|
|
describe('Intro', () => {
|
|
beforeEach(() => {
|
|
cy.visit('/')
|
|
})
|
|
|
|
describe('Cover Button are hidden when logged in', () => {
|
|
it('Sign in Cover Button', () => {
|
|
cy.get('.cover-button.btn-success')
|
|
.should('not.exist')
|
|
})
|
|
|
|
it('Features Cover Button', () => {
|
|
cy.get('.cover-button.btn-primary')
|
|
.should('not.exist')
|
|
})
|
|
})
|
|
|
|
describe('Cover Button are shown when logged out', () => {
|
|
beforeEach(() => {
|
|
cy.logout()
|
|
})
|
|
|
|
it('Sign in Cover Button', () => {
|
|
cy.get('.cover-button.btn-success')
|
|
.should('exist')
|
|
})
|
|
|
|
it('Features Cover Button', () => {
|
|
cy.get('.cover-button.btn-primary')
|
|
.should('exist')
|
|
})
|
|
})
|
|
|
|
it('Version can be opened and closed', () => {
|
|
cy.get('#versionModal')
|
|
.should('not.exist')
|
|
cy.get('#version')
|
|
.click()
|
|
cy.get('#versionModal')
|
|
.should('be.visible')
|
|
cy.get('#versionModal .modal-footer .btn')
|
|
.contains('Close')
|
|
.click()
|
|
cy.get('#versionModal')
|
|
.should('not.exist')
|
|
})
|
|
})
|