-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve UI tests for API modules #36187
Conversation
… toggle that needs to wait a bit longer and force using specific modules
ddcb8da
to
8771197
Compare
let isModuleVisible = await moduleManager.searchModule(page, {tag: 'statscarrier'} as FakerModule); | ||
expect(isModuleVisible).to.be.equal(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let isModuleVisible = await moduleManager.searchModule(page, {tag: 'statscarrier'} as FakerModule); | |
expect(isModuleVisible).to.be.equal(true); | |
const isModule1Visible = await moduleManager.searchModule(page, {tag: 'statscarrier'} as FakerModule); | |
expect(isModule1Visible).to.be.equal(true); |
isModuleVisible = await moduleManager.searchModule(page, {tag: 'pagesnotfound'} as FakerModule); | ||
expect(isModuleVisible).to.be.equal(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isModuleVisible = await moduleManager.searchModule(page, {tag: 'pagesnotfound'} as FakerModule); | |
expect(isModuleVisible).to.be.equal(true); | |
const isModule2Visible = await moduleManager.searchModule(page, {tag: 'pagesnotfound'} as FakerModule); | |
expect(isModule2Visible).to.be.equal(true); |
await testContext.addContextItem(this, 'testIdentifier', `checkModules${index}`, baseContext); | ||
|
||
await dashboardPage.goToSubMenu(page, dashboardPage.modulesParentLink, dashboardPage.modulesParentLink); | ||
// Extra wait for this one because the cache has been cleared by the previous API call | ||
await dashboardPage.goToSubMenu(page, dashboardPage.modulesParentLink, dashboardPage.modulesParentLink, 60000); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Always need to do that ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since the cache is cleared after the API call I think it's safer to wait a bit longer, the first page is really long to load
Full campaign: https://github.com/jolelievre/ga.tests.ui.pr/actions/runs/9130335672