Skip to content

Commit 5ae0837

Browse files
committed
chore: improve tests descriptions
1 parent 5345c66 commit 5ae0837

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/import-paths.test.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,32 +14,32 @@ const tester = new RuleTester({
1414
tester.run('import-paths', rule, {
1515
valid: [
1616
{
17-
name: 'relative import from not an alias directory',
17+
name: 'relative import from not an alias directory are allowed',
1818
filename: path.resolve('./src/index.ts'),
1919
code: `import baz from './baz/index';`,
2020
},
2121
{
22-
name: 'import from alias root',
22+
name: 'import from an alias root are possible',
2323
filename: path.resolve('./src/index.ts'),
2424
code: `import baz from '@foo';`,
2525
},
2626
{
27-
name: 'alias import from alias directory',
27+
name: 'files in alias directory may import files from the same alias',
2828
filename: path.resolve('./src/foo/index.ts'),
2929
code: `import z from '@foo/x/y/z';`,
3030
},
3131
{
32-
name: 'alias import from another alias directory',
32+
name: 'files in alias directory may import files from another aliases',
3333
filename: path.resolve('./src/foo/index.ts'),
3434
code: `import z from '@bar/x/y/z';`,
3535
},
3636
{
37-
name: 'relative import from subdirectory in file under alias directory',
37+
name: 'relative imports from subdirectory is allowed for files inside alias',
3838
filename: path.resolve('./src/foo/index.ts'),
3939
code: `import z from './x/y/z';`,
4040
},
4141
{
42-
name: 'relative import up from subdirectory in file under alias directory',
42+
name: 'relative imports from subdirectory is allowed for files inside alias (case with escalate directory)',
4343
filename: path.resolve('./src/foo/x/y/z/index.ts'),
4444
code: `import foo from '../../../index';`,
4545
},
@@ -53,7 +53,7 @@ tester.run('import-paths', rule, {
5353
output: `import z from '@foo/x/y/z';`,
5454
},
5555
{
56-
name: 'relative import from alias used in file under another alias must be fixed',
56+
name: 'relative import from alias used in another alias must be fixed',
5757
filename: path.resolve('./src/foo/index.ts'),
5858
code: `import z from '../bar/x/y/z';`,
5959
errors: ['Update import to @bar/x/y/z'],

0 commit comments

Comments
 (0)