aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/e2e/src/po/app.po.ts
blob: a636e825f11669b1b6bb5e156ef8c2905a243607 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
import { browser, by, element } from 'protractor'

export class AppPage {

  async closeWelcomeModal () {
    const firstHandle = await browser.getWindowHandle()

    if (await element(by.css('.configure-instance-button')).isPresent() === false) return

    await element(by.css('.configure-instance-button')).click()

    await browser.switchTo().window(firstHandle)

    await browser.refresh()

    await element(by.css('.form-group-checkbox')).click()
    await element(by.css('.action-button-cancel')).click()

    await browser.switchTo().window(firstHandle)
  }
}