Skip to content

Commit

Permalink
[Tests] export: add tests for a name collision with export * from
Browse files Browse the repository at this point in the history
Closes #1704.

Co-authored-by: Tom Prats <tom@tomify.me>
  • Loading branch information
ljharb and tomprats committed Aug 21, 2020
1 parent 5fe14e3 commit 1a67453
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Expand Up @@ -11,6 +11,9 @@ This change log adheres to standards from [Keep a CHANGELOG](http://keepachangel
- [`extensions`]/importType: Fix @/abc being treated as scoped module ([#1854], thanks [@3nuc])
- allow using rest operator in named export ([#1878], thanks [@foray1010])

### Changed
- [`export`]: add tests for a name collision with `export * from` ([#1704], thanks @tomprats)

## [2.22.0] - 2020-06-26
### Added
- [`no-unused-modules`]: consider exported TypeScript interfaces, types and enums ([#1819], thanks [@nicolashenry])
Expand Down Expand Up @@ -758,6 +761,7 @@ for info on changes for earlier releases.
[#1724]: https://github.com/benmosher/eslint-plugin-import/pull/1724
[#1722]: https://github.com/benmosher/eslint-plugin-import/issues/1722
[#1719]: https://github.com/benmosher/eslint-plugin-import/pull/1719
[#1704]: https://github.com/benmosher/eslint-plugin-import/issues/1704
[#1702]: https://github.com/benmosher/eslint-plugin-import/issues/1702
[#1691]: https://github.com/benmosher/eslint-plugin-import/pull/1691
[#1690]: https://github.com/benmosher/eslint-plugin-import/pull/1690
Expand Down Expand Up @@ -1266,3 +1270,4 @@ for info on changes for earlier releases.
[@beatrizrezener]: https://github.com/beatrizrezener
[@3nuc]: https://github.com/3nuc
[@foray1010]: https://github.com/foray1010
[@tomprats]: https://github.com/tomprats
9 changes: 9 additions & 0 deletions tests/src/rules/export.js
Expand Up @@ -35,6 +35,15 @@ ruleTester.run('export', rule, {
export { A, B };
`,
}),
test({
code: `
export * as A from './named-export-collision/a';
export * as B from './named-export-collision/b';
`,
parserOptions: {
ecmaVersion: 2020,
},
}),
],

invalid: [
Expand Down

0 comments on commit 1a67453

Please sign in to comment.