-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2747 from digitalfabrik/deps/upgrade_webauthn_tes…
…t_support deps/upgrade webauthn test support
- Loading branch information
Showing
6 changed files
with
1,330 additions
and
9 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
9 changes: 9 additions & 0 deletions
9
integreat_cms/static/src/js/__tests__/utils/mfa-utils.test.ts
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,9 @@ | ||
import { expect, test } from "vitest"; | ||
import { b64enc } from "../../utils/mfa-utils"; | ||
|
||
test("base64 and url encoding", () => { | ||
const testDataString = "https://example.com/?q=Hello+World!"; | ||
const testData = new TextEncoder().encode(testDataString); | ||
|
||
expect(b64enc(testData)).toBe("aHR0cHM6Ly9leGFtcGxlLmNvbS8_cT1IZWxsbytXb3JsZCE"); | ||
}); |
Oops, something went wrong.