|
1 | | -import { formatSwissSocialInsuranceNumber, isValidSwissIbanNumber, isValidSwissSocialInsuranceNumber } from "./swissStandards"; |
| 1 | +import { isValidSwissIbanNumber, isValidSwissSocialInsuranceNumber } from "./swissStandards"; |
2 | 2 |
|
3 | 3 | describe("Swiss standards test", () => { |
4 | 4 | test.each([ |
@@ -42,20 +42,4 @@ describe("Swiss standards test", () => { |
42 | 42 | ])("check if the social insurance number is valid or not", (socialInsuranceNumberToCheck, expected) => { |
43 | 43 | expect(isValidSwissSocialInsuranceNumber(socialInsuranceNumberToCheck)).toBe(expected); |
44 | 44 | }); |
45 | | - |
46 | | - test.each([ |
47 | | - [null as unknown as string, null, false], |
48 | | - ["7569217076985", "756.9217.0769.85", true], |
49 | | - ["7561234567891", "756.1234.5678.91", false], |
50 | | - ["75 61 23 456789 1", "756.1234.5678.91", false], |
51 | | - ["75 69 21 707698 5", "756.9217.0769.85", true], |
52 | | - ])( |
53 | | - "Check if the social insurance number gets formatted correctly", |
54 | | - (unformattedSocialInsuranceNumber, expectedSocialInsuranceNumber, expectedIsValid) => { |
55 | | - const result = formatSwissSocialInsuranceNumber(unformattedSocialInsuranceNumber); |
56 | | - |
57 | | - expect(result.socialInsuranceNumber).toBe(expectedSocialInsuranceNumber); |
58 | | - expect(result.isValidSwissSocialInsuranceNumber).toBe(expectedIsValid); |
59 | | - }, |
60 | | - ); |
61 | 45 | }); |
0 commit comments