@@ -150,7 +150,10 @@ var harnessSources = harnessCoreSources.concat([
150
150
"reuseProgramStructure.ts" ,
151
151
"cachingInServerLSHost.ts" ,
152
152
"moduleResolution.ts" ,
153
- "tsconfigParsing.ts"
153
+ "tsconfigParsing.ts" ,
154
+ "commandLineParsing.ts" ,
155
+ "convertCompilerOptionsFromJson.ts" ,
156
+ "convertTypingOptionsFromJson.ts"
154
157
] . map ( function ( f ) {
155
158
return path . join ( unittestsDirectory , f ) ;
156
159
} ) ) . concat ( [
@@ -162,18 +165,47 @@ var harnessSources = harnessCoreSources.concat([
162
165
return path . join ( serverDirectory , f ) ;
163
166
} ) ) ;
164
167
165
- var librarySourceMap = [
166
- { target : "lib .core.d.ts", sources : [ "header.d.ts" , "core.d.ts" ] } ,
167
- { target : "lib.dom .d.ts", sources : [ "importcore.d.ts" , "intl.d.ts" , "dom.generated.d.ts" ] , } ,
168
- { target : "lib.webworker .d.ts", sources : [ "importcore.d.ts" , "intl.d.ts" , "webworker.generated.d.ts" ] , } ,
169
- { target : "lib.scriptHost .d.ts", sources : [ "importcore.d.ts" , "scriptHost.d.ts" ] , } ,
170
- { target : "lib.d.ts" , sources : [ "header. d.ts", "core.d.ts" , "intl.d.ts" , "dom.generated.d.ts" , "webworker.importscripts.d.ts" , "scriptHost.d.ts" ] , } ,
171
- { target : "lib.core.es6. d.ts", sources : [ "header.d.ts" , "core.d.ts" , "es6.d.ts" ] } ,
172
- { target : "lib.es6 .d.ts", sources : [ "header.d.ts" , "es6.d.ts" , "core.d.ts" , "intl.d.ts" , "dom.generated.d.ts" , "dom.es6.d.ts" , "webworker.importscripts.d.ts" , "scriptHost.d.ts" ] } ,
173
- { target : "lib.core.es7. d.ts", sources : [ "header.d.ts" , "core.d.ts" , "es6.d.ts" , "es7.d.ts" ] } ,
174
- { target : "lib.es7.d.ts" , sources : [ "header. d.ts", "es6.d.ts" , "es7.d.ts" , "core.d.ts" , "intl.d.ts" , "dom.generated.d.ts" , "dom.es6.d.ts" , "webworker.importscripts.d.ts" , "scriptHost.d.ts" ] }
168
+ var es2015LibrarySources = [
169
+ "es2015 .core.d.ts",
170
+ "es2015.collection .d.ts",
171
+ "es2015.generator .d.ts",
172
+ "es2015.iterable .d.ts",
173
+ "es2015.promise. d.ts",
174
+ "es2015.proxy. d.ts",
175
+ "es2015.reflect .d.ts",
176
+ "es2015.symbol. d.ts",
177
+ "es2015.symbol.wellknown. d.ts",
175
178
] ;
176
179
180
+ var es2015LibrarySourceMap = es2015LibrarySources . map ( function ( source ) {
181
+ return { target : "lib." + source , sources : [ "header.d.ts" , source ] } ;
182
+ } ) ;
183
+
184
+ var es2016LibrarySource = [ "es2016.array.include.d.ts" ] ;
185
+
186
+ var es2016LibrarySourceMap = es2016LibrarySource . map ( function ( source ) {
187
+ return { target : "lib." + source , sources : [ "header.d.ts" , source ] } ;
188
+ } )
189
+
190
+ var hostsLibrarySources = [ "dom.generated.d.ts" , "webworker.importscripts.d.ts" , "scripthost.d.ts" ]
191
+
192
+ var librarySourceMap = [
193
+ // Host library
194
+ { target : "lib.dom.d.ts" , sources : [ "header.d.ts" , "dom.generated.d.ts" ] , } ,
195
+ { target : "lib.dom.iterable.d.ts" , sources : [ "header.d.ts" , "dom.iterable.d.ts" ] , } ,
196
+ { target : "lib.webworker.d.ts" , sources : [ "header.d.ts" , "webworker.generated.d.ts" ] , } ,
197
+ { target : "lib.scripthost.d.ts" , sources : [ "header.d.ts" , "scripthost.d.ts" ] , } ,
198
+
199
+ // JavaScript library
200
+ { target : "lib.es5.d.ts" , sources : [ "header.d.ts" , "es5.d.ts" ] } ,
201
+ { target : "lib.es2015.d.ts" , sources : [ "header.d.ts" , "es2015.d.ts" ] } ,
202
+ { target : "lib.es2016.d.ts" , sources : [ "header.d.ts" , "es2016.d.ts" ] } ,
203
+
204
+ // JavaScript + all host library
205
+ { target : "lib.d.ts" , sources : [ "header.d.ts" , "es5.d.ts" ] . concat ( hostsLibrarySources ) , } ,
206
+ { target : "lib.es6.d.ts" , sources : [ "header.d.ts" , "es5.d.ts" ] . concat ( es2015LibrarySources , hostsLibrarySources , "dom.iterable.d.ts" ) , } ,
207
+ ] . concat ( es2015LibrarySourceMap , es2016LibrarySourceMap ) ;
208
+
177
209
var libraryTargets = librarySourceMap . map ( function ( f ) {
178
210
return path . join ( builtLocalDirectory , f . target ) ;
179
211
} ) ;
@@ -212,7 +244,7 @@ function concatenateFiles(destinationFile, sourceFiles) {
212
244
}
213
245
214
246
var useDebugMode = true ;
215
- var host = ( process . env . host || process . env . TYPESCRIPT_HOST || "node" ) ;
247
+ var host = ( process . env . TYPESCRIPT_HOST || process . env . host || "node" ) ;
216
248
var compilerFilename = "tsc.js" ;
217
249
var LKGCompiler = path . join ( LKGDirectory , compilerFilename ) ;
218
250
var builtLocalCompiler = path . join ( builtLocalDirectory , compilerFilename ) ;
@@ -652,7 +684,7 @@ function deleteTemporaryProjectOutput() {
652
684
}
653
685
}
654
686
655
- function runConsoleTests ( defaultReporter , defaultSubsets , postLint ) {
687
+ function runConsoleTests ( defaultReporter , defaultSubsets ) {
656
688
cleanTestDirs ( ) ;
657
689
var debug = process . env . debug || process . env . d ;
658
690
tests = process . env . test || process . env . tests || process . env . t ;
@@ -685,13 +717,13 @@ function runConsoleTests(defaultReporter, defaultSubsets, postLint) {
685
717
subsetRegexes = subsets . map ( function ( sub ) { return "^" + sub + ".*$" ; } ) ;
686
718
subsetRegexes . push ( "^(?!" + subsets . join ( "|" ) + ").*$" ) ;
687
719
}
688
- subsetRegexes . forEach ( function ( subsetRegex ) {
720
+ subsetRegexes . forEach ( function ( subsetRegex , i ) {
689
721
tests = subsetRegex ? ' -g "' + subsetRegex + '"' : '' ;
690
722
var cmd = "mocha" + ( debug ? " --debug-brk" : "" ) + " -R " + reporter + tests + colors + ' -t ' + testTimeout + ' ' + run ;
691
723
console . log ( cmd ) ;
692
724
exec ( cmd , function ( ) {
693
725
deleteTemporaryProjectOutput ( ) ;
694
- if ( postLint ) {
726
+ if ( i === 0 ) {
695
727
var lint = jake . Task [ 'lint' ] ;
696
728
lint . addListener ( 'complete' , function ( ) {
697
729
complete ( ) ;
@@ -713,7 +745,7 @@ task("runtests-parallel", ["build-rules", "tests", builtLocalDirectory], functio
713
745
714
746
desc ( "Runs the tests using the built run.js file. Optional arguments are: t[ests]=regex r[eporter]=[list|spec|json|<more>] d[ebug]=true color[s]=false." ) ;
715
747
task ( "runtests" , [ "build-rules" , "tests" , builtLocalDirectory ] , function ( ) {
716
- runConsoleTests ( 'mocha-fivemat-progress-reporter' , [ ] , /*postLint*/ true ) ;
748
+ runConsoleTests ( 'mocha-fivemat-progress-reporter' , [ ] ) ;
717
749
} , { async : true } ) ;
718
750
719
751
desc ( "Generates code coverage data via instanbul" ) ;
@@ -871,7 +903,6 @@ task("update-sublime", ["local", serverFile], function() {
871
903
var tslintRuleDir = "scripts/tslint" ;
872
904
var tslintRules = ( [
873
905
"nextLineRule" ,
874
- "noNullRule" ,
875
906
"preferConstRule" ,
876
907
"booleanTriviaRule" ,
877
908
"typeOperatorSpacingRule" ,
@@ -927,6 +958,7 @@ var servicesLintTargets = [
927
958
"patternMatcher.ts" ,
928
959
"services.ts" ,
929
960
"shims.ts" ,
961
+ "jsTyping.ts"
930
962
] . map ( function ( s ) {
931
963
return path . join ( servicesDirectory , s ) ;
932
964
} ) ;
0 commit comments