File tree 3 files changed +14
-5
lines changed
3 files changed +14
-5
lines changed Original file line number Diff line number Diff line change 1
- bsb && echo $?
1
+ bsb
Original file line number Diff line number Diff line change 31
31
"scripts" : {
32
32
"test" : " go build -o test.exe scripts/test.go && ./test.exe" ,
33
33
"test-theme" : " go run scripts/test.go -no-install-global -no-ounit -no-mocha -no-bsb" ,
34
+ "test-bsb" : " go run scripts/test.go -no-install-global -no-ounit -no-mocha -no-theme" ,
34
35
"wtest" : " mocha './jscomp/test/**/*test.js' -R spec -w" ,
35
36
"cover" : " istanbul cover --report html ./node_modules/.bin/_mocha -- ./jscomp/test/**/*test.js && open coverage/index.html" ,
36
37
"coverage" : " istanbul cover ./node_modules/.bin/_mocha --report lcovonly -- './jscomp/test/*test.js' -R spec" ,
Original file line number Diff line number Diff line change @@ -167,9 +167,9 @@ func fatalError(err error) {
167
167
panic (err )
168
168
}
169
169
}
170
- func bsbInDir (dir string ) {
170
+ func bsbInDir (builddir , dir string ) {
171
171
172
- destDir := filepath .Join ("jscomp" , "build_tests" , dir )
172
+ destDir := filepath .Join (builddir , dir )
173
173
pattern , err := ioutil .ReadFile (filepath .Join (destDir , "output.ref" ))
174
174
fatalError (err )
175
175
argsB , err := ioutil .ReadFile (filepath .Join (destDir , "input.sh" ))
@@ -189,7 +189,7 @@ func bsbInDir(dir string) {
189
189
fmt .Println ("Failure to match" , pattern )
190
190
191
191
}
192
-
192
+ fmt . Println ( "failed in " , dir )
193
193
outS := string (out )
194
194
fmt .Println (outS )
195
195
fmt .Println (err )
@@ -257,6 +257,14 @@ func main() {
257
257
wg .Wait ()
258
258
}
259
259
if ! * noBsbTest {
260
- bsbInDir ("in_source" )
260
+ buildTestDir := filepath .Join ("jscomp" ,"build_tests" )
261
+ files , err := ioutil .ReadDir (buildTestDir )
262
+ checkError (err )
263
+
264
+ for _ , file := range files {
265
+ if file .IsDir (){
266
+ bsbInDir (buildTestDir ,file .Name ())
267
+ }
268
+ }
261
269
}
262
270
}
You can’t perform that action at this time.
0 commit comments