@@ -6,7 +6,7 @@ var join = require('path').join;
66
77var filename = join ( common . tmpDir , 'append.txt' ) ;
88
9- common . error ( 'appending to ' + filename ) ;
9+ console . error ( 'appending to ' + filename ) ;
1010
1111var currentFileData = 'ABCD' ;
1212
@@ -28,11 +28,11 @@ fs.appendFile(filename, s, function(e) {
2828 if ( e ) throw e ;
2929
3030 ncallbacks ++ ;
31- common . error ( 'appended to file' ) ;
31+ console . error ( 'appended to file' ) ;
3232
3333 fs . readFile ( filename , function ( e , buffer ) {
3434 if ( e ) throw e ;
35- common . error ( 'file read' ) ;
35+ console . error ( 'file read' ) ;
3636 ncallbacks ++ ;
3737 assert . equal ( Buffer . byteLength ( s ) , buffer . length ) ;
3838 } ) ;
@@ -46,11 +46,11 @@ fs.appendFile(filename2, s, function(e) {
4646 if ( e ) throw e ;
4747
4848 ncallbacks ++ ;
49- common . error ( 'appended to file2' ) ;
49+ console . error ( 'appended to file2' ) ;
5050
5151 fs . readFile ( filename2 , function ( e , buffer ) {
5252 if ( e ) throw e ;
53- common . error ( 'file2 read' ) ;
53+ console . error ( 'file2 read' ) ;
5454 ncallbacks ++ ;
5555 assert . equal ( Buffer . byteLength ( s ) + currentFileData . length , buffer . length ) ;
5656 } ) ;
@@ -61,17 +61,17 @@ var filename3 = join(common.tmpDir, 'append3.txt');
6161fs . writeFileSync ( filename3 , currentFileData ) ;
6262
6363var buf = new Buffer ( s , 'utf8' ) ;
64- common . error ( 'appending to ' + filename3 ) ;
64+ console . error ( 'appending to ' + filename3 ) ;
6565
6666fs . appendFile ( filename3 , buf , function ( e ) {
6767 if ( e ) throw e ;
6868
6969 ncallbacks ++ ;
70- common . error ( 'appended to file3' ) ;
70+ console . error ( 'appended to file3' ) ;
7171
7272 fs . readFile ( filename3 , function ( e , buffer ) {
7373 if ( e ) throw e ;
74- common . error ( 'file3 read' ) ;
74+ console . error ( 'file3 read' ) ;
7575 ncallbacks ++ ;
7676 assert . equal ( buf . length + currentFileData . length , buffer . length ) ;
7777 } ) ;
@@ -81,14 +81,14 @@ fs.appendFile(filename3, buf, function(e) {
8181var filename4 = join ( common . tmpDir , 'append4.txt' ) ;
8282fs . writeFileSync ( filename4 , currentFileData ) ;
8383
84- common . error ( 'appending to ' + filename4 ) ;
84+ console . error ( 'appending to ' + filename4 ) ;
8585
8686var m = 0o600 ;
8787fs . appendFile ( filename4 , n , { mode : m } , function ( e ) {
8888 if ( e ) throw e ;
8989
9090 ncallbacks ++ ;
91- common . error ( 'appended to file4' ) ;
91+ console . error ( 'appended to file4' ) ;
9292
9393 // windows permissions aren't unix
9494 if ( ! common . isWindows ) {
@@ -98,15 +98,15 @@ fs.appendFile(filename4, n, { mode: m }, function(e) {
9898
9999 fs . readFile ( filename4 , function ( e , buffer ) {
100100 if ( e ) throw e ;
101- common . error ( 'file4 read' ) ;
101+ console . error ( 'file4 read' ) ;
102102 ncallbacks ++ ;
103103 assert . equal ( Buffer . byteLength ( '' + n ) + currentFileData . length ,
104104 buffer . length ) ;
105105 } ) ;
106106} ) ;
107107
108108process . on ( 'exit' , function ( ) {
109- common . error ( 'done' ) ;
109+ console . error ( 'done' ) ;
110110 assert . equal ( 8 , ncallbacks ) ;
111111
112112 fs . unlinkSync ( filename ) ;
0 commit comments