specter-desktop/cypress/integration/spec_empty_specter_home.js
al-munazzim 6755046e4b
chore: bump Cypress to 13.17.0 (#2646)
Co-authored-by: Nazim <nazim@openclaw.ai>
2026-08-11 19:14:45 +02:00

51 lines
1.7 KiB
JavaScript

describe('Completely empty specter-home', () => {
before(() => {
cy.task("clear:specter-home")
cy.visit('/welcome/about')
})
it('Click around on the welcome page', () => {
cy.contains('Welcome to Specter')
cy.get('[data-cy="settings-btn"]').click()
cy.contains('Backup and Restore')
cy.contains('Authentication').click()
cy.contains('USB Devices').click()
cy.contains('Hardware Devices Bridge')
cy.get('main').scrollTo('top')
cy.contains('Tor').click()
cy.contains('Tor configurations')
cy.get('#btn_plugins').click()
cy.contains("Plugins in Production")
})
it('Setup password protection', () => {
cy.get('[data-cy="settings-btn"]').click()
cy.contains('Authentication').click()
cy.get('[data-cy="authentication-selection"]').select('Password Protection')
cy.get('[data-cy="admin-password-input"]').type('satoshi')
cy.get('[data-cy="save-auth-settings-btn"]').click()
cy.contains('Admin password successfully updated')
})
it('Login with password and deactivate password protection again', () => {
cy.get('body').then(($body) => {
// Cypress 13 keeps browser context when testIsolation is disabled for this
// stateful suite. If the session cookie survived from the previous test,
// we are already logged in and can go straight to settings.
if ($body.find('[data-cy="admin-password"]').length) {
cy.get('[data-cy="admin-password"]').type('satoshi')
cy.get('[data-cy="login-btn"]').click()
}
})
cy.get('[data-cy="settings-btn"]').click()
cy.contains('Authentication').click()
cy.get('[data-cy="authentication-selection"]').select('None')
cy.get('[data-cy="save-auth-settings-btn"]').click()
})
})