Skip to content

Commit

Permalink
Avoid requireNoCache in pkgJson.spec (#647)
Browse files Browse the repository at this point in the history
See #644
  • Loading branch information
raphinesse committed Aug 15, 2018
1 parent 9443f92 commit f8b9f6a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions integration-tests/pkgJson.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ describe('pkgJson', function () {
function pluginVersion (pluginName) {
const p = path.join(project, 'plugins', pluginName, 'package.json');
expect(p).toExist();
return requireNoCache(p).version;
return fs.readJsonSync(p).version;
}

function getPkgJson (propPath) {
Expand All @@ -81,7 +81,7 @@ describe('pkgJson', function () {
return keys.reduce((obj, key) => {
expect(obj).toBeDefined();
return obj[key];
}, requireNoCache(pkgJsonPath));
}, fs.readJsonSync(pkgJsonPath));
}

function getCfg () {
Expand Down Expand Up @@ -260,7 +260,7 @@ describe('pkgJson', function () {
}).then(function () {
return cordova.plugin('add', PLUGIN, {save: true});
}).then(function () {
const iosJson = requireNoCache(path.join(project, 'platforms/ios/ios.json'));
const iosJson = fs.readJsonSync(path.join(project, 'platforms/ios/ios.json'));
expect(iosJson.installed_plugins[PLUGIN]).toBeDefined();

// Check that installed version satisfies the dependency spec
Expand Down

0 comments on commit f8b9f6a

Please sign in to comment.