This repository has been archived by the owner on Nov 1, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 473
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(Merge day) browser-engine-gecko-beta (67) -> browser-engine-gecko-re…
…lease (67).
- Loading branch information
Showing
19 changed files
with
957 additions
and
85 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
133 changes: 133 additions & 0 deletions
133
...t/java/mozilla/components/browser/engine/gecko/fetch/geckoview/GeckoViewFetchTestCases.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,133 @@ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | ||
|
||
package mozilla.components.lib.fetch.geckoview | ||
|
||
import androidx.test.annotation.UiThreadTest | ||
import androidx.test.core.app.ApplicationProvider | ||
import androidx.test.filters.MediumTest | ||
import mozilla.components.browser.engine.gecko.fetch.GeckoViewFetchClient | ||
import mozilla.components.concept.fetch.Client | ||
import org.junit.Assert.assertTrue | ||
import org.junit.Test | ||
|
||
@MediumTest | ||
@Suppress("TooManyFunctions") | ||
class GeckoViewFetchTestCases : mozilla.components.tooling.fetch.tests.FetchTestCases() { | ||
override fun createNewClient(): Client = GeckoViewFetchClient(ApplicationProvider.getApplicationContext()) | ||
|
||
@Test | ||
@UiThreadTest | ||
fun clientInstance() { | ||
assertTrue(createNewClient() is GeckoViewFetchClient) | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithDefaultHeaders() { | ||
super.get200WithDefaultHeaders() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithGzippedBody() { | ||
super.get200WithGzippedBody() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200OverridingDefaultHeaders() { | ||
super.get200OverridingDefaultHeaders() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithUserAgent() { | ||
super.get200WithUserAgent() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithDuplicatedCacheControlRequestHeaders() { | ||
super.get200WithDuplicatedCacheControlRequestHeaders() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithDuplicatedCacheControlResponseHeaders() { | ||
super.get200WithDuplicatedCacheControlResponseHeaders() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithHeaders() { | ||
super.get200WithHeaders() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithReadTimeout() { | ||
super.get200WithReadTimeout() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithStringBody() { | ||
super.get200WithStringBody() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get302FollowRedirects() { | ||
super.get302FollowRedirects() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get302FollowRedirectsDisabled() { | ||
super.get302FollowRedirectsDisabled() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get404WithBody() { | ||
super.get404WithBody() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun post200WithBody() { | ||
super.post200WithBody() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun put201FileUpload() { | ||
super.put201FileUpload() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithCookiePolicy() { | ||
super.get200WithCookiePolicy() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithContentTypeCharset() { | ||
super.get200WithContentTypeCharset() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun get200WithCacheControl() { | ||
super.get200WithCacheControl() | ||
} | ||
|
||
@Test | ||
@UiThreadTest | ||
override fun getThrowsIOExceptionWhenHostNotReachable() { | ||
super.getThrowsIOExceptionWhenHostNotReachable() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.