Bug 1643129 - Add a reload to GV auth prompt test r=geckoview-reviewers,aklotz

This is needed in order to catch certain problems with LoginStorage.jsm.

Differential Revision: https://phabricator.services.mozilla.com/D78142
This commit is contained in:
James Willcox 2020-06-10 05:44:48 +00:00
Родитель 84c6991d13
Коммит f48f8ed0ee
1 изменённых файлов: 9 добавлений и 5 удалений

Просмотреть файл

@ -102,16 +102,20 @@ class PromptDelegateTest : BaseSessionTest() {
})
}
@Test fun authTest() {
sessionRule.session.loadTestPath("/basic-auth/foo/bar")
sessionRule.waitUntilCalled(object : Callbacks.PromptDelegate {
@AssertCalled(count = 1)
@Test fun dismissAuthTest() {
sessionRule.delegateUntilTestEnd(object : Callbacks.PromptDelegate {
@AssertCalled(count = 2)
override fun onAuthPrompt(session: GeckoSession, prompt: PromptDelegate.AuthPrompt): GeckoResult<PromptDelegate.PromptResponse>? {
//TODO: Figure out some better testing here.
return null
}
})
mainSession.loadTestPath("/basic-auth/foo/bar")
mainSession.waitForPageStop()
mainSession.reload()
mainSession.waitForPageStop()
}
@Test fun buttonTest() {