mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-30 01:04:49 -05:00
Add test to make sure /// is preserved when removeComments is false
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
//// [tests/cases/compiler/emitTopOfFileTripleSlashCommentOnNotEmittedNodeIfRemoveCommentsIsFalse.ts] ////
|
||||
|
||||
//// [file0.ts]
|
||||
|
||||
var x = 10
|
||||
|
||||
//// [file1.ts]
|
||||
/// <reference path="file0.ts" />
|
||||
declare var OData: any;
|
||||
|
||||
/// <reference path="file0.ts" />
|
||||
interface F { }
|
||||
|
||||
|
||||
|
||||
|
||||
//// [file0.js]
|
||||
var x = 10;
|
||||
//// [file1.js]
|
||||
/// <reference path="file0.ts" />
|
||||
@@ -0,0 +1,16 @@
|
||||
=== tests/cases/compiler/file1.ts ===
|
||||
/// <reference path="file0.ts" />
|
||||
declare var OData: any;
|
||||
>OData : Symbol(OData, Decl(file1.ts, 1, 11))
|
||||
|
||||
/// <reference path="file0.ts" />
|
||||
interface F { }
|
||||
>F : Symbol(F, Decl(file1.ts, 1, 23))
|
||||
|
||||
|
||||
|
||||
=== tests/cases/compiler/file0.ts ===
|
||||
|
||||
var x = 10
|
||||
>x : Symbol(x, Decl(file0.ts, 1, 3))
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
=== tests/cases/compiler/file1.ts ===
|
||||
/// <reference path="file0.ts" />
|
||||
declare var OData: any;
|
||||
>OData : any
|
||||
|
||||
/// <reference path="file0.ts" />
|
||||
interface F { }
|
||||
>F : F
|
||||
|
||||
|
||||
|
||||
=== tests/cases/compiler/file0.ts ===
|
||||
|
||||
var x = 10
|
||||
>x : number
|
||||
>10 : number
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
// @comments: true
|
||||
|
||||
// @Filename: file0.ts
|
||||
var x = 10
|
||||
|
||||
// @Filename: file1.ts
|
||||
/// <reference path="file0.ts" />
|
||||
declare var OData: any;
|
||||
|
||||
/// <reference path="file0.ts" />
|
||||
interface F { }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user