lunchclass / absolute

Absolute is a web-based O2O(Online to Offline) platform like Siren-Order for Starbucks. We are focused on creating the platform that is portable, cheaper, easier, decentralized and appless.
Apache License 2.0
103 stars 31 forks source link

Apply color on test result log #538

Closed cs-lee closed 6 years ago

cs-lee commented 6 years ago

Color is missing after using child_process.exec() function. Change it to spawn() function to inherit parent stdio.

ISSUE=none

nadongguri commented 6 years ago

@cs-lee, please check it on Windows platform

c:\absolute>absolute test [21:49:46] Requiring external module ts-node/register [21:49:47] Using gulpfile c:\absolute\gulpfile.ts [21:49:47] Starting 'webpack'... ts-loader: Using typescript@2.6.1 and c:\absolute\tsconfig.json [21:49:50] Version: webpack 3.8.1 Asset Size Chunks Chunk Names main.js 27.5 kB 0 [emitted] main push_service_worker.js 3.29 kB 1 [emitted] push_service_worker cache_service_worker.js 3.48 kB 2 [emitted] cache_service_worker manifest.json 184 bytes [emitted] index.html 712 bytes [emitted] [21:49:50] Finished 'webpack' after 3.4 s [21:49:50] Starting 'test'... [21:49:50] Finished 'test' after 3.33 ms Error: spawn jest ENOENT at exports._errnoException (util.js:1020:11) at Process.ChildProcess._handle.onexit (internal/child_process.js:193:32) at onErrorNT (internal/child_process.js:367:16) at _combinedTickCallback (internal/process/next_tick.js:80:11) at process._tickCallback (internal/process/next_tick.js:104:9)

cs-lee commented 6 years ago

@nadongguri Window error is fixed. Please review.