Files
freeCodeCamp/api/utils/index.test.ts
Tom 7aeb4ab76b feat(api): setup jest in new api (#49709)
* feat(api): setup jest in new api

* feat: sample tests
2023-03-16 20:33:40 +05:30

16 lines
345 B
TypeScript

import { base64URLEncode, challenge, verifier } from '.';
describe('utils', () => {
test('base64URLEncode', () => {
expect(base64URLEncode(Buffer.from('test'))).toEqual('dGVzdA');
});
test('verifier', () => {
expect(verifier).toHaveLength(43);
});
test('challenge', () => {
expect(challenge).toHaveLength(43);
});
});