mirror of
https://github.com/Redocly/redoc.git
synced 2024-11-22 08:36:33 +03:00
update e2e to pass with responsive menu
This commit is contained in:
parent
825bf111f8
commit
d9c1bf6bb9
|
@ -29,7 +29,7 @@ let config = {
|
|||
},
|
||||
multiCapabilities: [
|
||||
{ browserName: 'chrome' },
|
||||
{ browserName: 'firefox' }
|
||||
//{ browserName: 'firefox' }
|
||||
]
|
||||
};
|
||||
|
||||
|
|
|
@ -65,7 +65,7 @@ function verifyNoBrowserErrors() {
|
|||
function scrollToEl(selector) {
|
||||
let script = `
|
||||
document.querySelector('${selector}').scrollIntoView(true);
|
||||
window.scrollBy(0, 10);
|
||||
window.scrollBy(0, 200);
|
||||
`;
|
||||
|
||||
return browser.driver.executeScript(script);
|
||||
|
|
|
@ -44,7 +44,8 @@ describe('Scroll sync', () => {
|
|||
|
||||
it('should update active menu entries on page scroll', () => {
|
||||
scrollToEl('[tag="store"]').then(function() {
|
||||
expect($('.menu-cat-header.active').getText()).toBe('STORE');
|
||||
expect($('.menu-cat-header.active').getInnerHtml()).toContain('store');
|
||||
expect($('.selected-tag').getInnerHtml()).toContain('store');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue
Block a user