mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-19 02:53:27 +02:00
Refactor stream log output to a utility.
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
var util = require('util')
|
||||
|
||||
var syrup = require('syrup')
|
||||
var split = require('split')
|
||||
var Promise = require('bluebird')
|
||||
|
||||
var wire = require('../../../wire')
|
||||
@@ -50,10 +49,7 @@ module.exports = syrup.serial()
|
||||
})
|
||||
.then(function(out) {
|
||||
lifecycle.share('InputAgent shell', out)
|
||||
out.pipe(split())
|
||||
.on('data', function(chunk) {
|
||||
log.info('Agent says: "%s"', chunk)
|
||||
})
|
||||
streamutil.talk(log, 'InputAgent says: "%s"', out)
|
||||
})
|
||||
.then(function() {
|
||||
return devutil.waitForPort(adb, options.serial, agent.port)
|
||||
|
||||
Reference in New Issue
Block a user