Files
codeql/javascript/ql/integration-tests/diagnostics/internal-error/src/my_failure.ts
Cornelius Riemenschneider b7b475d13b JS: Move all integration tests.
We no longer need the platform-specific directories, so simplify the test organization.
If you don't want this change, just skip merging this PR.
It's purely optional.

The PR also deletes a spurious qlpack.yml that I missed when converting the tests to pytest.
2024-08-28 10:43:08 +02:00

18 lines
468 B
TypeScript

type Output<K, S extends any[]> = {
(...args: S): any;
};
declare function createThing<K extends string, S extends any[]>(
type: K,
fn: (...args: S) => any
): Output<K, S>;
const one = createThing("one", () => ({}));
const two = createThing("two", () => ({}));
const three = createThing("three", (cursor: string) => null);
const four = createThing("four", (error: number) => null);
type Events = Array<typeof one | typeof two | typeof three | typeof four>;