chore: remove unnecessary version test

This commit is contained in:
Christian Capeans 2024-04-04 10:59:52 +02:00
parent e23830c818
commit 2314bc3311

View File

@ -1,34 +0,0 @@
'use strict';
const coffee = require('coffee');
const utils = require('../../../utils');
describe('--version', () => {
let appPath;
let currentVersion;
beforeAll(async () => {
const testApps = utils.instances.getTestApps();
appPath = testApps.at(0);
currentVersion = require(`${appPath}/package.json`).dependencies['@strapi/strapi'];
});
it('should output version with argument', async () => {
await coffee
.spawn('npm', ['run', '-s', 'strapi', '--', 'version'], { cwd: appPath })
.expect('stderr', '')
.expect('stdout', `${currentVersion}\n`)
.expect('code', 0)
.end();
});
it('should output version with --version', async () => {
await coffee
.spawn('npm', ['run', '-s', 'strapi', '--', '--version'], { cwd: appPath })
.expect('stdout', `${currentVersion}\n`)
.expect('code', 0)
.end();
});
});