|
1 | 1 | 'use babel';
|
2 | 2 |
|
3 | 3 | import { join } from 'path';
|
4 |
| -// eslint-disable-next-line import/no-extraneous-dependencies |
| 4 | +// eslint-disable-next-line import/no-extraneous-dependencies, import/no-unresolved |
5 | 5 | import { remove } from 'fs-extra';
|
6 | 6 |
|
7 | 7 | const validPathElixirc = join(__dirname, 'fixtures', 'elixirc', 'valid.ex');
|
@@ -37,27 +37,27 @@ describe('The elixirc provider for Linter', () => {
|
37 | 37 | waitsForPromise(() =>
|
38 | 38 | atom.workspace.open(errorMode1PathElixirc).then(editor =>
|
39 | 39 | lint(editor)).then((messages) => {
|
40 |
| - expect(messages.length).toBe(1); |
41 |
| - expect(messages[0].severity).toBe('error'); |
42 |
| - expect(messages[0].html).not.toBeDefined(); |
43 |
| - expect(messages[0].excerpt).toBe('(ArgumentError) Dangerous is not available'); |
44 |
| - expect(messages[0].location.file).toBe(errorMode1PathElixirc); |
45 |
| - expect(messages[0].location.position).toEqual([[1, 0], [1, 32]]); |
46 |
| - }), |
| 40 | + expect(messages.length).toBe(1); |
| 41 | + expect(messages[0].severity).toBe('error'); |
| 42 | + expect(messages[0].html).not.toBeDefined(); |
| 43 | + expect(messages[0].excerpt).toBe('(ArgumentError) Dangerous is not available'); |
| 44 | + expect(messages[0].location.file).toBe(errorMode1PathElixirc); |
| 45 | + expect(messages[0].location.position).toEqual([[1, 0], [1, 32]]); |
| 46 | + }), |
47 | 47 | );
|
48 | 48 | });
|
49 | 49 |
|
50 | 50 | it('works with mode 2 errors', () => {
|
51 | 51 | waitsForPromise(() =>
|
52 | 52 | atom.workspace.open(errorMode2PathElixirc).then(editor =>
|
53 | 53 | lint(editor)).then((messages) => {
|
54 |
| - expect(messages.length).toBe(1); |
55 |
| - expect(messages[0].severity).toBe('error'); |
56 |
| - expect(messages[0].html).not.toBeDefined(); |
57 |
| - expect(messages[0].excerpt).toBe('(CompileError) module Usefulness is not loaded and could not be found'); |
58 |
| - expect(messages[0].location.file).toBe(errorMode2PathElixirc); |
59 |
| - expect(messages[0].location.position).toEqual([[3, 2], [3, 20]]); |
60 |
| - }), |
| 54 | + expect(messages.length).toBe(1); |
| 55 | + expect(messages[0].severity).toBe('error'); |
| 56 | + expect(messages[0].html).not.toBeDefined(); |
| 57 | + expect(messages[0].excerpt).toBe('(CompileError) module Usefulness is not loaded and could not be found'); |
| 58 | + expect(messages[0].location.file).toBe(errorMode2PathElixirc); |
| 59 | + expect(messages[0].location.position).toEqual([[3, 2], [3, 20]]); |
| 60 | + }), |
61 | 61 | );
|
62 | 62 | });
|
63 | 63 |
|
@@ -117,13 +117,13 @@ describe('The elixirc provider for Linter', () => {
|
117 | 117 | waitsForPromise(() =>
|
118 | 118 | atom.workspace.open(errorMode2PathMix).then(editor =>
|
119 | 119 | lint(editor)).then((messages) => {
|
120 |
| - expect(messages.length).toBe(1); |
121 |
| - expect(messages[0].severity).toBe('error'); |
122 |
| - expect(messages[0].html).not.toBeDefined(); |
123 |
| - expect(messages[0].excerpt).toBe('(CompileError) Identicon.Image.__struct__/1 is undefined, cannot expand struct Identicon.Image'); |
124 |
| - expect(messages[0].location.file).toBe(errorMode2PathMix); |
125 |
| - expect(messages[0].location.position).toEqual([[11, 4], [11, 30]]); |
126 |
| - }), |
| 120 | + expect(messages.length).toBe(1); |
| 121 | + expect(messages[0].severity).toBe('error'); |
| 122 | + expect(messages[0].html).not.toBeDefined(); |
| 123 | + expect(messages[0].excerpt).toBe('(CompileError) Identicon.Image.__struct__/1 is undefined, cannot expand struct Identicon.Image'); |
| 124 | + expect(messages[0].location.file).toBe(errorMode2PathMix); |
| 125 | + expect(messages[0].location.position).toEqual([[11, 4], [11, 30]]); |
| 126 | + }), |
127 | 127 | );
|
128 | 128 | });
|
129 | 129 |
|
|
0 commit comments