[Flaky tests] Click a more explicit button (#136091) (#136126)

(cherry picked from commit 6a043110cd)

Co-authored-by: Alejandro Fernández Haro <alejandro.haro@elastic.co>
This commit is contained in:
Kibana Machine 2022-07-11 14:17:27 -04:00 committed by GitHub
parent d43f206c2a
commit 6424292862
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -16,8 +16,8 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
describe('General "click"', () => {
beforeEach(async () => {
await common.navigateToApp('home');
// Just click on the top div and expect it's still there... we're just testing the click event generation
await common.clickAndValidate('kibanaChrome', 'kibanaChrome');
// Just clicking the top-nav-button and expecting it's still there... we're just testing the click event generation
await common.clickAndValidate('toggleNavButton', 'toggleNavButton');
});
it('should emit a "click" event', async () => {
@ -28,6 +28,8 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
expect(targets.includes('DIV')).to.be(true);
expect(targets.includes('id=kibana-body')).to.be(true);
expect(targets.includes('data-test-subj=kibanaChrome')).to.be(true);
expect(targets.includes('BUTTON')).to.be(true);
expect(targets.includes('data-test-subj=toggleNavButton')).to.be(true);
});
});
}