Skip to content

Commit

Permalink
spec migrate from shelljs to fs-extra
Browse files Browse the repository at this point in the history
  • Loading branch information
Christopher J. Brody committed May 29, 2018
1 parent 28457fd commit c11756a
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions spec/create.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@
under the License.
*/

var fs = require('fs');
const fs = require('fs-extra');

var path = require('path');

var shell = require('shelljs');
var requireFresh = require('import-fresh');

var create = require('..');
Expand All @@ -35,12 +35,12 @@ var project = path.join(tmpDir, appName);

// Setup and teardown test dirs
beforeEach(function () {
shell.rm('-rf', project);
shell.mkdir('-p', tmpDir);
fs.removeSync(project);
fs.ensureDirSync(tmpDir);
});
afterEach(function () {
process.chdir(path.join(__dirname, '..')); // Needed to rm the dir on Windows.
shell.rm('-rf', tmpDir);
fs.removeSync(tmpDir);
});

describe('cordova create checks for valid-identifier', function () {
Expand Down Expand Up @@ -285,7 +285,7 @@ describe('create end-to-end', function () {
});

it('should successfully run with existing, empty destination', function () {
shell.mkdir('-p', project);
fs.ensureDirSync(project);
return create(project, appId, appName, {}, events)
.then(checkProject);
});
Expand Down

0 comments on commit c11756a

Please sign in to comment.