File tree Expand file tree Collapse file tree 5 files changed +26
-1
lines changed
Expand file tree Collapse file tree 5 files changed +26
-1
lines changed Original file line number Diff line number Diff line change @@ -1042,6 +1042,12 @@ declare module td {
10421042 * while creating the final output.
10431043 */
10441044declare module td {
1045+ /**
1046+ * Reset the reflection id.
1047+ *
1048+ * Used by the test cases to ensure the reflection ids won't change between runs.
1049+ */
1050+ function resetReflectionID ( ) : void ;
10451051 /**
10461052 * Defines the available reflection kinds.
10471053 */
Original file line number Diff line number Diff line change @@ -3409,6 +3409,15 @@ var td;
34093409 * Current reflection id.
34103410 */
34113411 var REFLECTION_ID = 0 ;
3412+ /**
3413+ * Reset the reflection id.
3414+ *
3415+ * Used by the test cases to ensure the reflection ids won't change between runs.
3416+ */
3417+ function resetReflectionID ( ) {
3418+ REFLECTION_ID = 0 ;
3419+ }
3420+ td . resetReflectionID = resetReflectionID ;
34123421 /**
34133422 * Defines the available reflection kinds.
34143423 */
Original file line number Diff line number Diff line change @@ -78,6 +78,8 @@ module.exports = function(grunt)
7878
7979 settings . inputFiles = [ path ] ;
8080 settings . expandInputFiles ( ) ;
81+ TD . resetReflectionID ( ) ;
82+
8183 var result = converter . convert ( settings . inputFiles , settings ) ;
8284 var data = JSON . stringify ( result . project . toObject ( ) , null , ' ' ) ;
8385 data = data . split ( TD . normalizePath ( base ) ) . join ( '%BASE%' ) ;
Original file line number Diff line number Diff line change @@ -76,7 +76,6 @@ module td
7676 var inherited :string [ ] = [ ] ;
7777 var typeParameters :{ [ name :string ] :Type } = { } ;
7878
79-
8079 return compile ( ) ;
8180
8281
Original file line number Diff line number Diff line change @@ -16,6 +16,15 @@ module td
1616 */
1717 var REFLECTION_ID :number = 0 ;
1818
19+ /**
20+ * Reset the reflection id.
21+ *
22+ * Used by the test cases to ensure the reflection ids won't change between runs.
23+ */
24+ export function resetReflectionID ( ) {
25+ REFLECTION_ID = 0 ;
26+ }
27+
1928 /**
2029 * Defines the available reflection kinds.
2130 */
You can’t perform that action at this time.
0 commit comments