test: make test less flaky (#1553)
* test: make test less flaky * fixup * fix lint
This commit is contained in:
parent
d53430fee5
commit
07d8045617
|
@ -13,12 +13,15 @@ fixture`014-compose-post-privacy.js`
|
||||||
|
|
||||||
test('Changes post privacy', async t => {
|
test('Changes post privacy', async t => {
|
||||||
await loginAsFoobar(t)
|
await loginAsFoobar(t)
|
||||||
|
await sleep(2000)
|
||||||
await t
|
await t
|
||||||
.expect(postPrivacyButton.getAttribute('aria-label')).eql('Adjust privacy (currently Public)')
|
.expect(postPrivacyButton.getAttribute('aria-label')).eql('Adjust privacy (currently Public)')
|
||||||
.click(postPrivacyButton)
|
.click(postPrivacyButton)
|
||||||
|
.expect(getNthPostPrivacyOptionInDialog(2).exists).ok({ timeout: 30000 })
|
||||||
.click(getNthPostPrivacyOptionInDialog(2))
|
.click(getNthPostPrivacyOptionInDialog(2))
|
||||||
.expect(postPrivacyButton.getAttribute('aria-label')).eql('Adjust privacy (currently Unlisted)')
|
.expect(postPrivacyButton.getAttribute('aria-label')).eql('Adjust privacy (currently Unlisted)')
|
||||||
.click(postPrivacyButton)
|
.click(postPrivacyButton)
|
||||||
|
.expect(getNthPostPrivacyOptionInDialog(1).exists).ok({ timeout: 30000 })
|
||||||
.click(getNthPostPrivacyOptionInDialog(1))
|
.click(getNthPostPrivacyOptionInDialog(1))
|
||||||
.expect(postPrivacyButton.getAttribute('aria-label')).eql('Adjust privacy (currently Public)')
|
.expect(postPrivacyButton.getAttribute('aria-label')).eql('Adjust privacy (currently Public)')
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue