File tree Expand file tree Collapse file tree 1 file changed +10
-8
lines changed Expand file tree Collapse file tree 1 file changed +10
-8
lines changed Original file line number Diff line number Diff line change @@ -22,8 +22,16 @@ var touch = function(fileName) {
22
22
fs . closeSync ( fs . openSync ( fileName , 'w' ) ) ;
23
23
} ;
24
24
25
- // restart nw1 then test
26
- exec ( 'monit restart nw1 && sleep 5' , function ( ) {
25
+
26
+ // restart nw1, wait for it to do that, then test
27
+ exec ( 'monit restart nw1 && sleep 10' , function ( ) {
28
+ var notOkToStart = true ;
29
+
30
+ var monit = spawn ( 'monit' , [ 'summary' ] ) ;
31
+ monit . stdout . on ( 'data' , function ( data ) {
32
+ console . log ( data . toString ( ) . split ( '\n' ) [ 3 ] )
33
+ } ) ;
34
+
27
35
if ( ! userFileName ) runAll ( ) ;
28
36
else runSingle ( userFileName ) ;
29
37
} ) ;
@@ -101,12 +109,6 @@ function testMock (fileName, t) {
101
109
t . ok ( isEqual , imageFileName + ' should be pixel perfect' ) ;
102
110
}
103
111
104
- console . log ( 'before request' )
105
- var ps = spawn ( 'ps aux | grep nw' ) ;
106
- ps . on ( 'data' , function ( data ) {
107
- console . log ( data ) ;
108
- } ) ;
109
-
110
112
request ( options )
111
113
. pipe ( savedImageStream )
112
114
. on ( 'close' , checkImage ) ;
You can’t perform that action at this time.
0 commit comments