chore: replace superspawn & child_process with execa (#862)

* chore: added execa dependency

Co-authored-by: Raphael von der Grün <raphinesse@gmail.com>

* chore: execa - drop superspawn in android_sdk

Co-authored-by: Raphael von der Grün <raphinesse@gmail.com>

* chore: execa - drop superspawn in build

* chore: execa - drop superspawn in check_reqs

Plus: Remove useless trimming of execa output

Co-authored-by: Raphael von der Grün <raphinesse@gmail.com>

* chore: execa - drop superspawn in emulator

Co-authored-by: Raphael von der Grün <raphinesse@gmail.com>

* chore: execa - drop superspawn in device

Co-authored-by: Raphael von der Grün <raphinesse@gmail.com>

* chore: execa - drop superspawn in run_java_unit_tests

* chore: execa - drop superspawn in ProjectBuilder

Co-authored-by: Raphael von der Grün <raphinesse@gmail.com>

* chore: execa - drop superspawn in adb

* chore: execa - drop superspawn in plugin.spec

* chore: execa - replace child_process in log

* chore: execa - replace child_process in check_reqs

* chore: execa - replace child_process in emulator

Co-authored-by: エリス <erisu@users.noreply.github.com>
This commit is contained in:
Raphael von der Grün
2020-01-06 23:15:22 +01:00
committed by GitHub
parent e3cc75caff
commit fd57909730
16 changed files with 138 additions and 157 deletions
+3 -2
View File
@@ -21,7 +21,8 @@ const os = require('os');
const fs = require('fs');
const path = require('path');
const shell = require('shelljs');
const { PluginInfoProvider, superspawn } = require('cordova-common');
const execa = require('execa');
const { PluginInfoProvider } = require('cordova-common');
const createBin = path.join(__dirname, '../../bin/create');
const fakePluginPath = path.join(__dirname, 'fixtures/cordova-plugin-fake');
@@ -44,7 +45,7 @@ describe('plugin add', function () {
const pluginInfo = new PluginInfoProvider().get(fakePluginPath);
return Promise.resolve()
.then(() => superspawn.spawn(createBin, [projectPath, projectid, projectname]))
.then(() => execa(createBin, [projectPath, projectid, projectname]))
.then(() => {
const Api = require(path.join(projectPath, 'cordova/Api.js'));
return new Api('android', projectPath).addPlugin(pluginInfo);