fix: use position: fixed to avoid forcing Cypress (#39605)
This commit is contained in:
parent
2f4d1c2804
commit
4f0959df1d
@ -9,7 +9,7 @@
|
||||
font-family: 'Lato', sans-serif;
|
||||
height: var(--header-height);
|
||||
background: var(--theme-color);
|
||||
position: absolute;
|
||||
position: fixed;
|
||||
z-index: 1000;
|
||||
color: var(--gray-00);
|
||||
width: 100%;
|
||||
|
@ -52,7 +52,7 @@ describe('Learn Landing page (not logged in)', () => {
|
||||
describe('Quotes', () => {
|
||||
beforeEach(() => {
|
||||
cy.visit('/');
|
||||
cy.contains("Get started (it's free)").click({ force: true });
|
||||
cy.contains("Get started (it's free)").click();
|
||||
});
|
||||
|
||||
it('Should show a quote', () => {
|
||||
@ -71,7 +71,7 @@ describe('Quotes', () => {
|
||||
describe('Superblocks and Blocks', () => {
|
||||
beforeEach(() => {
|
||||
cy.visit('/');
|
||||
cy.contains("Get started (it's free)").click({ force: true });
|
||||
cy.contains("Get started (it's free)").click();
|
||||
});
|
||||
|
||||
it('Has first superblock and block collapsed by default', () => {
|
||||
@ -93,30 +93,26 @@ describe('Superblocks and Blocks', () => {
|
||||
});
|
||||
it('Superblocks should be collapsable and foldable', () => {
|
||||
cy.contains(superBlockNames[0])
|
||||
.click({
|
||||
force: true
|
||||
})
|
||||
.click()
|
||||
.should('have.attr', 'aria-expanded', 'false');
|
||||
cy.contains('Basic HTML and HTML5').should('not.be.visible');
|
||||
|
||||
cy.contains(superBlockNames[0])
|
||||
.click({
|
||||
force: true
|
||||
})
|
||||
.click()
|
||||
.should('have.attr', 'aria-expanded', 'true');
|
||||
cy.contains('Basic HTML and HTML5').should('be.visible');
|
||||
});
|
||||
|
||||
it('Blocks should be collapsable and foldable', () => {
|
||||
cy.contains('Basic HTML and HTML5')
|
||||
.click({ force: true })
|
||||
.click()
|
||||
.should('have.attr', 'aria-expanded', 'false');
|
||||
cy.contains('Introduction to Basic HTML and HTML5').should(
|
||||
'not.be.visible'
|
||||
);
|
||||
|
||||
cy.contains('Basic HTML and HTML5')
|
||||
.click({ force: true })
|
||||
.click()
|
||||
.should('have.attr', 'aria-expanded', 'true');
|
||||
cy.contains('Introduction to Basic HTML and HTML5').should('be.visible');
|
||||
});
|
||||
|
@ -4,7 +4,7 @@ describe('The `Update my account settings` button works properly', function() {
|
||||
beforeEach(() => {
|
||||
cy.visit('/');
|
||||
|
||||
cy.contains("Get started (it's free)").click({ force: true });
|
||||
cy.contains("Get started (it's free)").click();
|
||||
});
|
||||
|
||||
it('Should get rendered', function() {
|
||||
@ -17,7 +17,7 @@ describe('The `Update my account settings` button works properly', function() {
|
||||
});
|
||||
|
||||
it('Should take user to their account settings when clicked', function() {
|
||||
cy.contains('Update my account settings').click({ force: true });
|
||||
cy.contains('Update my account settings').click();
|
||||
cy.url().should('include', '/settings');
|
||||
});
|
||||
});
|
||||
|
@ -4,7 +4,7 @@ describe('The `View my Portfolio` button works properly', function() {
|
||||
beforeEach(() => {
|
||||
cy.visit('/');
|
||||
|
||||
cy.contains("Get started (it's free)").click({ force: true });
|
||||
cy.contains("Get started (it's free)").click();
|
||||
});
|
||||
|
||||
it('Button gets rendered', function() {
|
||||
@ -17,7 +17,7 @@ describe('The `View my Portfolio` button works properly', function() {
|
||||
});
|
||||
|
||||
it('Button takes user to their portfolio when clicked', function() {
|
||||
cy.contains('View my Portfolio').click({ force: true });
|
||||
cy.contains('View my Portfolio').click();
|
||||
cy.url().should('include', '/developmentuser');
|
||||
});
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user