Browse Source

failing tests for #669

gh-669
Rich-Harris 9 years ago
parent
commit
fce6287fd6
  1. 3
      test/form/unused-var/_config.js
  2. 7
      test/form/unused-var/_expected/amd.js
  3. 5
      test/form/unused-var/_expected/cjs.js
  4. 3
      test/form/unused-var/_expected/es6.js
  5. 8
      test/form/unused-var/_expected/iife.js
  6. 11
      test/form/unused-var/_expected/umd.js
  7. 6
      test/form/unused-var/foo.js
  8. 2
      test/form/unused-var/main.js
  9. 3
      test/function/tracks-late-alias-mutations/_config.js
  10. 7
      test/function/tracks-late-alias-mutations/bar.js
  11. 1
      test/function/tracks-late-alias-mutations/foo.js
  12. 4
      test/function/tracks-late-alias-mutations/main.js

3
test/form/unused-var/_config.js

@ -0,0 +1,3 @@
module.exports = {
description: 'omits unused var declaration'
};

7
test/form/unused-var/_expected/amd.js

@ -0,0 +1,7 @@
define(function () { 'use strict';
var foo = 'lol';
console.log( foo );
});

5
test/form/unused-var/_expected/cjs.js

@ -0,0 +1,5 @@
'use strict';
var foo = 'lol';
console.log( foo );

3
test/form/unused-var/_expected/es6.js

@ -0,0 +1,3 @@
var foo = 'lol';
console.log( foo );

8
test/form/unused-var/_expected/iife.js

@ -0,0 +1,8 @@
(function () {
'use strict';
var foo = 'lol';
console.log( foo );
}());

11
test/form/unused-var/_expected/umd.js

@ -0,0 +1,11 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory() :
typeof define === 'function' && define.amd ? define(factory) :
(factory());
}(this, function () { 'use strict';
var foo = 'lol';
console.log( foo );
}));

6
test/form/unused-var/foo.js

@ -0,0 +1,6 @@
var foo = 'lol';
var bar = 'wut';
var baz = bar || foo;
export { foo };

2
test/form/unused-var/main.js

@ -0,0 +1,2 @@
import { foo } from './foo.js';
console.log( foo );

3
test/function/tracks-late-alias-mutations/_config.js

@ -0,0 +1,3 @@
module.exports = {
description: 'tracks mutations of late aliases'
};

7
test/function/tracks-late-alias-mutations/bar.js

@ -0,0 +1,7 @@
import { foo } from './foo';
var f;
f = foo;
f.wasMutated = true;
export var bar = 'whatever';

1
test/function/tracks-late-alias-mutations/foo.js

@ -0,0 +1 @@
export var foo = {};

4
test/function/tracks-late-alias-mutations/main.js

@ -0,0 +1,4 @@
import { foo } from './foo';
import { bar } from './bar';
assert.ok( foo.wasMutated );
Loading…
Cancel
Save