Skip to content

Commit

Permalink
WIP: commented invalid tests for #416. need good messages
Browse files Browse the repository at this point in the history
  • Loading branch information
benmosher committed Jul 5, 2016
1 parent babfb9f commit f5cfe7c
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 12 deletions.
13 changes: 13 additions & 0 deletions tests/src/rules/named.js
Original file line number Diff line number Diff line change
Expand Up @@ -240,5 +240,18 @@ ruleTester.run('named', rule, {
code: 'import { default as barDefault } from "./re-export"',
errors: [`default not found in './re-export'`],
}),

// issue #416
// todo: update error message to indicate parse issue in deepest module
// test({
// code: `
// import {
// Navigation,
// Drawer,
// Layout,
// Content,
// Header,
// } from 'react-mdl'`,
// }),
],
})
23 changes: 11 additions & 12 deletions tests/src/rules/namespace.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,18 +107,6 @@ const valid = [
]

const invalid = [

// issue #416: todo: proper parse error
// test({
// code: `
// import * as ReactMDL from 'react-mdl';
// let Navigation = ReactMDL.Navigation;
// let Drawer = ReactMDL.Drawer;
// let Layout = ReactMDL.Layout;
// let Content = ReactMDL.Content;
// let Header = ReactMDL.Content;`,
// }),

test({code: "import * as foo from './common';",
errors: ["No exported names found in module './common'."]}),

Expand Down Expand Up @@ -199,6 +187,17 @@ const invalid = [
errors: [`'default' not found in imported namespace 'ree'.`],
}),

// issue #416: todo: proper parse error
// test({
// code: `
// import * as ReactMDL from 'react-mdl';
// let Navigation = ReactMDL.Navigation;
// let Drawer = ReactMDL.Drawer;
// let Layout = ReactMDL.Layout;
// let Content = ReactMDL.Content;
// let Header = ReactMDL.Content;`,
// }),

]

///////////////////////
Expand Down

0 comments on commit f5cfe7c

Please sign in to comment.