Skip to content

Commit

Permalink
apply suggested changes
Browse files Browse the repository at this point in the history
  • Loading branch information
JKobrynski committed Feb 20, 2024
1 parent c6fc74d commit 309335e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/unit/sanitizeStringForJSONParseTest.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import sanitizeStringForJSONParse from '../../.github/libs/sanitizeStringForJSONParse';

// Bad inputs should cause an error to be thrown
const badInputs = [null, undefined, 42, true];
const badInputs: Array<null | undefined | number | boolean> = [null, undefined, 42, true];

// Invalid JSON Data should be able to get parsed and the parsed result should match the input text.
const invalidJSONData: string[][] = [
const invalidJSONData: Array<[string, string]> = [
['Hello \t world!', 'Hello \t world!'],
['Hello \n world!', 'Hello \n world!'],
['Hello \n\tworld!', 'Hello \n\tworld!'],
Expand All @@ -21,7 +21,7 @@ const invalidJSONData: string[][] = [
];

// Valid JSON Data should be able to get parsed and the input text should be unmodified.
const validJSONData: string[][] = [
const validJSONData: Array<[string, string]> = [
['', ''],
['Hello world!', 'Hello world!'],
['Hello\\\\world!', 'Hello\\\\world!'],
Expand Down

0 comments on commit 309335e

Please sign in to comment.