| Index: third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/iframed-credentialscontainer.html
|
| diff --git a/third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/iframed-credentialscontainer.html b/third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/iframed-credentialscontainer.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..289c5d2ed5ce34fd282c58169f14a570f3b66ed2
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/iframed-credentialscontainer.html
|
| @@ -0,0 +1,47 @@
|
| +<!DOCTYPE html>
|
| +<script>
|
| +if (window.testRunner)
|
| + testRunner.addMockCredentialManagerResponse("id", "name", "", "password");
|
| +
|
| +navigator.credentials.get({ 'password': true })
|
| + .then(c => {
|
| + window.top.postMessage({
|
| + "credential": c,
|
| + "exception": null
|
| + }, "*");
|
| + })
|
| + .catch(omg => {
|
| + window.top.postMessage({
|
| + "credential": null,
|
| + "exception": omg.name
|
| + }, "*");
|
| + });
|
| +
|
| +navigator.credentials.store(new PasswordCredential({'id': 'name', 'password': 'password' }))
|
| + .then(c => {
|
| + window.top.postMessage({
|
| + "credential": c,
|
| + "exception": null
|
| + }, "*");
|
| + })
|
| + .catch(omg => {
|
| + window.top.postMessage({
|
| + "credential": null,
|
| + "exception": omg.name
|
| + }, "*");
|
| + });
|
| +
|
| +navigator.credentials.requireUserMediation()
|
| + .then(c => {
|
| + window.top.postMessage({
|
| + "credential": c,
|
| + "exception": null
|
| + }, "*");
|
| + })
|
| + .catch(omg => {
|
| + window.top.postMessage({
|
| + "credential": null,
|
| + "exception": omg.name
|
| + }, "*");
|
| + });
|
| +</script>
|
|
|