@@ -22,10 +22,13 @@ var assert = require('yeoman-assert');
2222var shell = require ( 'shelljs' ) ;
2323
2424//See http://yeoman.io/authoring/testing.html
25+ var restApiAppType = "Rest API" ;
26+ var commandLineAppType = "Command Line" ;
27+ var defaultAppType = restApiAppType ;
2528
2629var appTypes = [
27- "Rest API" ,
28- 'Command Line'
30+ restApiAppType ,
31+ commandLineAppType
2932] ;
3033
3134var entityStores = [
@@ -70,17 +73,25 @@ var featuresset = [
7073 [ ] ,
7174 [ 'jmx' ] ,
7275 [ 'mixin scripting' ] ,
73- [ 'security' ] ,
7476 [ 'jmx' , 'mixin scripting' ] ,
75- [ 'jmx' , 'scripting' ] ,
76- [ 'mixin scripting' , 'scripting' ] ,
77- [ 'jmx' , 'mixin scripting' , 'scripting' ]
77+ [ 'security' ] ,
78+ [ 'jmx' , 'security' ] ,
79+ [ 'mixin scripting' , 'security' ] ,
80+ [ 'jmx' , 'mixin scripting' , 'security' ] ,
81+ [ 'envisage' ] ,
82+ [ 'jmx' , 'envisage' ] ,
83+ [ 'mixin scripting' , 'envisage' ] ,
84+ [ 'jmx' , 'mixin scripting' , 'envisage' ] ,
85+ [ 'security' , 'envisage' ] ,
86+ [ 'jmx' , 'security' , 'envisage' ] ,
87+ [ 'mixin scripting' , 'security' , 'envisage' ] ,
88+ [ 'jmx' , 'mixin scripting' , 'security' , 'envisage' ]
7889] ;
7990
8091// test with all defaults first.
8192test ( ) ;
8293
83- if ( process . env . TEST_ALL === 'yes' ) {
94+ if ( process . env . TEST_ALL === 'yes' ) {
8495 // All Tests !!!!
8596 appTypes . forEach ( function ( appType ) {
8697 entityStores . forEach ( function ( entitystore ) {
@@ -102,23 +113,23 @@ if(process.env.TEST_ALL === 'yes') {
102113 } ) ;
103114
104115 entityStores . forEach ( function ( entityStore ) {
105- test ( "Rest API" , entityStore , "Rdf" , "Memcache" , "Codahale" , "[]" ) ;
116+ test ( defaultAppType , entityStore , "Rdf" , "Memcache" , "Codahale" , "[]" ) ;
106117 } ) ;
107118
108119 indexings . forEach ( function ( indexing ) {
109- test ( "Rest API" , "Memory" , indexing , "Memcache" , "Codahale" , "[]" ) ;
120+ test ( defaultAppType , "Memory" , indexing , "Memcache" , "Codahale" , "[]" ) ;
110121 } ) ;
111122
112123 cachings . forEach ( function ( caching ) {
113- test ( "Rest API" , "Memory" , "Rdf" , caching , "Codahale" , "[]" ) ;
124+ test ( defaultAppType , "Memory" , "Rdf" , caching , "Codahale" , "[]" ) ;
114125 } ) ;
115126
116127 metricses . forEach ( function ( metrics ) {
117- test ( "Rest API" , "Memory" , "Rdf" , "Memcache" , metrics , "[]" ) ;
128+ test ( defaultAppType , "Memory" , "Rdf" , "Memcache" , metrics , "[]" ) ;
118129 } ) ;
119130
120131 featuresset . forEach ( function ( feature ) {
121- test ( "Rest API" , "Memory" , "Rdf" , "Memcache" , "Codahale" , feature ) ;
132+ test ( defaultAppType , "Memory" , "Rdf" , "Memcache" , "Codahale" , feature ) ;
122133 } ) ;
123134}
124135
@@ -129,13 +140,13 @@ function test(appType, entityStore, indexing, caching, metrics, features) {
129140 + indexing + ' Indexing - '
130141 + caching + ' Caching - '
131142 + metrics + ' Metrics' ;
132- if ( features && features . length > 0 ) {
143+ if ( features && features . length > 0 ) {
133144 testName += ' - ' + features . toString ( ) . replace ( new RegExp ( ',' , 'g' ) , ' - ' ) ;
134145 }
135146 var testDirName = testName . replace ( new RegExp ( ' - ' , 'g' ) , '_' ) . replace ( new RegExp ( ' ' , 'g' ) , '_' ) ;
136147 it ( testName ,
137148 function ( ) {
138- console . log ( "\n\nTest: " + testName ) ;
149+ console . log ( "\n\nTest: " + testName ) ;
139150 this . timeout ( 60000 ) ;
140151 return helpers . run ( path . join ( __dirname , '../app' ) )
141152 . inDir ( path . join ( __dirname , '../build/npm-test/' + testDirName ) )
0 commit comments