Accepted baselines.

This commit is contained in:
Daniel Rosenwasser 2016-06-13 23:33:36 -07:00
parent 318e957377
commit d54094c6f7
6 changed files with 98 additions and 0 deletions

View file

@ -0,0 +1,21 @@
//// [shorthandOfExportedEntity01_targetES2015_CommonJS.ts]
export const test = "test";
export function foo () {
const x = { test };
}
//// [shorthandOfExportedEntity01_targetES2015_CommonJS.js]
"use strict";
exports.test = "test";
function foo() {
const x = { test };
}
exports.foo = foo;
//// [shorthandOfExportedEntity01_targetES2015_CommonJS.d.ts]
export declare const test: string;
export declare function foo(): void;

View file

@ -0,0 +1,13 @@
=== tests/cases/compiler/shorthandOfExportedEntity01_targetES2015_CommonJS.ts ===
export const test = "test";
>test : Symbol(test, Decl(shorthandOfExportedEntity01_targetES2015_CommonJS.ts, 1, 12))
export function foo () {
>foo : Symbol(foo, Decl(shorthandOfExportedEntity01_targetES2015_CommonJS.ts, 1, 27))
const x = { test };
>x : Symbol(x, Decl(shorthandOfExportedEntity01_targetES2015_CommonJS.ts, 4, 7))
>test : Symbol(test, Decl(shorthandOfExportedEntity01_targetES2015_CommonJS.ts, 4, 13))
}

View file

@ -0,0 +1,15 @@
=== tests/cases/compiler/shorthandOfExportedEntity01_targetES2015_CommonJS.ts ===
export const test = "test";
>test : string
>"test" : string
export function foo () {
>foo : () => void
const x = { test };
>x : { test: string; }
>{ test } : { test: string; }
>test : string
}

View file

@ -0,0 +1,21 @@
//// [shorthandOfExportedEntity02_targetES5_CommonJS.ts]
export const test = "test";
export function foo () {
const x = { test };
}
//// [shorthandOfExportedEntity02_targetES5_CommonJS.js]
"use strict";
exports.test = "test";
function foo() {
var x = { test: exports.test };
}
exports.foo = foo;
//// [shorthandOfExportedEntity02_targetES5_CommonJS.d.ts]
export declare const test: string;
export declare function foo(): void;

View file

@ -0,0 +1,13 @@
=== tests/cases/compiler/shorthandOfExportedEntity02_targetES5_CommonJS.ts ===
export const test = "test";
>test : Symbol(test, Decl(shorthandOfExportedEntity02_targetES5_CommonJS.ts, 1, 12))
export function foo () {
>foo : Symbol(foo, Decl(shorthandOfExportedEntity02_targetES5_CommonJS.ts, 1, 27))
const x = { test };
>x : Symbol(x, Decl(shorthandOfExportedEntity02_targetES5_CommonJS.ts, 4, 7))
>test : Symbol(test, Decl(shorthandOfExportedEntity02_targetES5_CommonJS.ts, 4, 13))
}

View file

@ -0,0 +1,15 @@
=== tests/cases/compiler/shorthandOfExportedEntity02_targetES5_CommonJS.ts ===
export const test = "test";
>test : string
>"test" : string
export function foo () {
>foo : () => void
const x = { test };
>x : { test: string; }
>{ test } : { test: string; }
>test : string
}