gecko-dev/testing/web-platform/tests/webauthn/makecredential-badargs-accountinformation.https.html
James Graham 824f4e083b Bug 1340474 - Update web-platform-tests to revision eba2c70d536caaeef540966bc8ac7822417ab867, a=testonly
MozReview-Commit-ID: 1GaV7z8d0Xc

--HG--
rename : testing/web-platform/tests/preload/link_header_preload_delay_onload.html.headers => testing/web-platform/tests/preload/link-header-preload-delay-onload.html.headers
rename : testing/web-platform/tests/preload/link_header_preload.html.headers => testing/web-platform/tests/preload/link-header-preload.html.headers
2017-02-20 11:52:05 +00:00

34 lines
2.4 KiB
HTML

<!DOCTYPE html>
<meta charset="utf-8">
<title>WebAuthn makeCredential accountInformation Tests</title>
<link rel="author" title="Adam Powers" href="mailto:adam@fidoalliance.org">
<link rel="help" href="https://w3c.github.io/webauthn/#iface-credential">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src=helpers.js></script>
<body></body>
<script>
standardSetup(function() {
"use strict";
// accountInformation bad values
new MakeCredentialTest({path: "accountInformation", value: undefined}).testBadArgs("accountInformation missing");
new MakeCredentialTest("accountInformation", "hi mom").testBadArgs("accountInformation is string");
new MakeCredentialTest("accountInformation", {}).testBadArgs("accountInformation is empty object");
// accountInformation.rpDisplayName
new MakeCredentialTest({path: "accountInformation.rpDisplayName", value: undefined}).testBadArgs("accountInformation missing rpDisplayName");
new MakeCredentialTest("accountInformation.rpDisplayName", {}).testBadArgs("Bad accountInformation: rpDisplayName is object");
new MakeCredentialTest("accountInformation.rpDisplayName", null).testBadArgs("Bad accountInformation: rpDisplayName is null");
new MakeCredentialTest("accountInformation.rpDisplayName", "").testBadArgs("Bad accountInformation: rpDisplayName is empty String");
// accountInformation.displayName
new MakeCredentialTest({path: "accountInformation.displayName", value: undefined}).testBadArgs("accountInformation missing displayName");
new MakeCredentialTest("accountInformation.displayName", {}).testBadArgs("Bad accountInformation: displayName is object");
new MakeCredentialTest("accountInformation.displayName", null).testBadArgs("Bad accountInformation: displayName is null");
new MakeCredentialTest("accountInformation.displayName", "").testBadArgs("Bad accountInformation: displayName is empty String");
// accountInformation.id
new MakeCredentialTest({path: "accountInformation.id", value: undefined}).testBadArgs("accountInformation missing id");
new MakeCredentialTest("accountInformation.id", {}).testBadArgs("Bad accountInformation: id is object");
new MakeCredentialTest("accountInformation.id", null).testBadArgs("Bad accountInformation: id is null");
new MakeCredentialTest("accountInformation.id", "").testBadArgs("Bad accountInformation: id is empty String");
});
</script>