mirror of https://github.com/lukechilds/rollup.git
Rich Harris
9 years ago
3 changed files with 16 additions and 0 deletions
@ -0,0 +1,3 @@ |
|||
module.exports = { |
|||
description: 'calls non-function default exports' |
|||
}; |
@ -0,0 +1,9 @@ |
|||
function x () { |
|||
global.answer = 'x'; |
|||
} |
|||
|
|||
function y () { |
|||
global.answer = 'y'; |
|||
} |
|||
|
|||
export default Math.random() < 0.5 ? x : y; |
@ -0,0 +1,4 @@ |
|||
import foo from './foo.js'; |
|||
foo(); |
|||
|
|||
assert.ok( /[xy]/.test( global.answer ) ); |
Loading…
Reference in new issue