diff --git a/test/docker.spec.js b/test/docker.spec.js index f19c62a1efdb1dcc8a1bceb5b8ee84a15d993a22..48b1b3fd2859e7a917be03fe8ce348aeb7a0221a 100644 --- a/test/docker.spec.js +++ b/test/docker.spec.js @@ -1,22 +1,17 @@ -'use strict' +import { test } from 'ava' -const sinon = require('sinon') -const test = require('tape') +import { execSync } from 'child_process' +import sinon from 'sinon' -const {execSync} = require('child_process') - -const log = require('../src/npmlog-env') +import { log } from '../' const docker = !!process.env.WECHATY_DOCKER !docker && test('Docker test skipped', function(t) { t.pass('not in docker, skip docker tests') - t.end() }) docker && test('Docker smoking test', function(t) { const n = execSync('ps | grep Xvfb | wc -l') - t.equal(n, 1, 'should has Xvfb started') - - t.end() + t.is(n, 1, 'should has Xvfb started') })