fix: complete jump-hop frontend wiring
This commit is contained in:
26
src/services/publicWorkCode.test.ts
Normal file
26
src/services/publicWorkCode.test.ts
Normal file
@@ -0,0 +1,26 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
|
||||
import {
|
||||
buildJumpHopPublicWorkCode,
|
||||
isSameJumpHopPublicWorkCode,
|
||||
} from './publicWorkCode';
|
||||
|
||||
describe('publicWorkCode', () => {
|
||||
it('builds and matches jump-hop public work codes from profile ids', () => {
|
||||
expect(buildJumpHopPublicWorkCode('jump-hop-profile-12345678')).toBe(
|
||||
'JH-12345678',
|
||||
);
|
||||
expect(
|
||||
isSameJumpHopPublicWorkCode(
|
||||
'jh-12345678',
|
||||
'jump-hop-profile-12345678',
|
||||
),
|
||||
).toBe(true);
|
||||
expect(
|
||||
isSameJumpHopPublicWorkCode(
|
||||
'jump hop profile 12345678',
|
||||
'jump-hop-profile-12345678',
|
||||
),
|
||||
).toBe(true);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user