Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
fisker committed Jul 1, 2021
1 parent 8e2d456 commit 77832e2
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion test/fixtures/space/one-space.js
@@ -1,3 +1,3 @@
console.log([
1
1,
]);
2 changes: 1 addition & 1 deletion test/fixtures/space/two-spaces.js
@@ -1,3 +1,3 @@
console.log([
1
1,
]);
2 changes: 1 addition & 1 deletion test/fixtures/typescript/child/sub-child/four-spaces.ts
@@ -1,3 +1,3 @@
console.log([
4
4,
]);
2 changes: 1 addition & 1 deletion test/fixtures/typescript/two-spaces.tsx
@@ -1,3 +1,3 @@
console.log([
2
2,
]);
8 changes: 4 additions & 4 deletions test/lint-text.js
Expand Up @@ -278,14 +278,14 @@ test('find configurations close to linted file', async t => {

test('typescript files', async t => {
let {results} = await xo.lintText(`console.log([
2
2,
]);
`, {filePath: 'fixtures/typescript/two-spaces.tsx'});

t.true(hasRule(results, '@typescript-eslint/indent'));

({results} = await xo.lintText(`console.log([
2
2,
]);
`, {filePath: 'fixtures/typescript/two-spaces.tsx', space: 2}));
t.is(results[0].errorCount, 0);
Expand All @@ -297,13 +297,13 @@ test('typescript files', async t => {
t.is(results[0].errorCount, 0);

({results} = await xo.lintText(`console.log([
4
4,
]);
`, {filePath: 'fixtures/typescript/child/sub-child/four-spaces.ts'}));
t.true(hasRule(results, '@typescript-eslint/indent'));

({results} = await xo.lintText(`console.log([
4
4,
]);
`, {filePath: 'fixtures/typescript/child/sub-child/four-spaces.ts', space: 4}));
t.is(results[0].errorCount, 0);
Expand Down

0 comments on commit 77832e2

Please sign in to comment.