blob: da8e5345960f9d4c6264edac3991d220554efe97 [file] [log] [blame]
<!DOCTYPE html>
<title>Web Authentication API: PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable().</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
promise_test(function(t) {
internals.mockCredentialsMessenger;
return PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable().then(function(result) {
assert_equals(result, false);
});
}, "PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable() without any available authenticators.");
promise_test(function(t) {
internals.mockCredentialsMessenger.setDidUserVerifyingPlatformAuthenticatorPresent();
return PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable().then(function(result) {
assert_equals(result, true);
});
}, "PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable() with available authenticators.");
</script>