-
Notifications
You must be signed in to change notification settings - Fork 2.3k
chore(test): move element_spec.js off of the control flow #4997
chore(test): move element_spec.js off of the control flow #4997
Conversation
Reference #4995 |
cb4a7d7
to
99d8192
Compare
ff2ad33
to
789bcde
Compare
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's port these to TS to make them a bit easier to work with.
You can use the no-floating-promises TSLint rule (https://palantir.github.io/tslint/rules/no-floating-promises/) to make sure everything is awaited.
|
||
usernameInput.clear().sendKeys('Jane'); | ||
expect(name.getText()).toEqual('Jane'); | ||
await usernameInput.clear().sendKeys('Jane'); |
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.
What does usernameInput.clear()
return? I'm suprised it's not a promise you need to await
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.
Hmmm... For some reason I thought I could still chain these together. I guess not?
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.
I split these up but they should stay together. You should be able to chain these together.
3a469b5
to
55e01ae
Compare
95f5f5a
to
6a542ab
Compare
So far it looks like starting up webdriver-manager + circleci is flaky. I am also removing all the tests to try to pass only my test. |
db651f6
to
7df618f
Compare
1b9c24e
to
e51ad92
Compare
Update circleci to support async await. For the basicConf test suite: - Only run the element_spec test in the Protractor config, we will add back other specs as we migrate the basicConf off of the control flow. - In the Protractor configuration file, set `SELENIUM_PROMISE_MANAGER` to false. - Refactor to use async / await. - Refactor `var` to use either `const` or `let`.
e51ad92
to
ef7f3e1
Compare
First step on the journey to Selenium 4! |
So why were these tests failing? I forgot maybe 4-ish await statements. I made all the changes to remove all Why did Travis fail? Node 6 does not support async / await. |
For the basicConf test suite:
back other specs as we migrate the basicConf off of the control
flow.
SELENIUM_PROMISE_MANAGER
to false.var
to use eitherconst
orlet
.