Add 'bytesRead' and 'path' to fs.ReadStream

This commit is contained in:
Lukas Zech
2016-11-10 17:04:54 +01:00
parent c4afd27a44
commit 057e24868a
2 changed files with 4 additions and 0 deletions
+2
View File
@@ -423,6 +423,8 @@ function stream_readable_pipe_test() {
var r = fs.createReadStream('file.txt');
var z = zlib.createGzip({ finishFlush: zlib.Z_FINISH });
var w = fs.createWriteStream('file.txt.gz');
console.log(r.bytesRead);
console.log(r.path);
r.pipe(z).pipe(w);
r.close();
}