MCPcopy Create free account
hub / github.com/ardatan/graphql-tools / assertStringArray

Function assertStringArray

packages/utils/tests/mapSchema.test.ts:629–633  ·  view source on GitHub ↗
(input: Array<unknown>)

Source from the content-addressed store, hash-verified

627 }
628
629 function assertStringArray(input: Array<unknown>): asserts input is Array<string> {
630 if (input.some(item => typeof item !== 'string')) {
631 throw new Error('All items in array should be strings.');
632 }
633 }
634
635 function checkErrors(expectedCount: number, ...expectedNames: Array<string>) {
636 return function ({ errors = [], data }: ExecutionResult) {

Callers 1

checkErrorsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected