Skip to content

Commit

Permalink
mark expected typescript errors
Browse files Browse the repository at this point in the history
  • Loading branch information
chriskalmar committed Jan 29, 2021
1 parent a1872b4 commit fa223de
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/engine/mutation/Mutation.spec.ts
Expand Up @@ -54,6 +54,7 @@ describe('Mutation', () => {
// eslint-disable-next-line no-new
new Mutation({
name: 'example',
// @ts-expect-error on purpose
type: 12346,
});
}
Expand Down Expand Up @@ -93,6 +94,7 @@ describe('Mutation', () => {
name: 'example',
type: MUTATION_TYPE_CREATE,
description: 'mutate the world',
// @ts-expect-error on purpose
attributes: ['anything', { foo: 'bar' }],
});

Expand Down Expand Up @@ -162,6 +164,7 @@ describe('Mutation', () => {
type: MUTATION_TYPE_CREATE,
description: 'mutate the world',
attributes: ['anything'],
// @ts-expect-error on purpose
preProcessor: 'not-a-function',
});
}
Expand All @@ -177,6 +180,7 @@ describe('Mutation', () => {
type: MUTATION_TYPE_CREATE,
description: 'mutate the world',
attributes: ['anything'],
// @ts-expect-error on purpose
postProcessor: 'not-a-function',
});
}
Expand All @@ -192,6 +196,7 @@ describe('Mutation', () => {
type: MUTATION_TYPE_UPDATE,
description: 'mutate the world',
attributes: ['anything'],
// @ts-expect-error on purpose
fromState: { foo: 'bar' },
});
}
Expand All @@ -207,6 +212,7 @@ describe('Mutation', () => {
type: MUTATION_TYPE_UPDATE,
description: 'mutate the world',
attributes: ['anything'],
// @ts-expect-error on purpose
toState: 123,
});
}
Expand Down Expand Up @@ -280,7 +286,9 @@ describe('Mutation', () => {
type: MUTATION_TYPE_UPDATE,
description: 'mutate the world',
attributes: ['anything'],
preProcessor() {},
preProcessor() {
return {};
},
postProcessor() {},
});

Expand Down Expand Up @@ -332,6 +340,7 @@ describe('Mutation', () => {
};

function fn() {
// @ts-expect-error on purpose
processEntityMutations(entity, mutations);
}

Expand All @@ -342,6 +351,7 @@ describe('Mutation', () => {
const mutations = [{ foo: 'bar' }];

function fn() {
// @ts-expect-error on purpose
processEntityMutations(entity, mutations);
}

Expand Down

0 comments on commit fa223de

Please sign in to comment.