Fix lowercasing of coverage driver

This commit is contained in:
Shivam Mathur 2020-01-26 16:15:39 +05:30
parent fbe1419ce4
commit d613c975f6
No known key found for this signature in database
GPG Key ID: 3E13E4C8591ACC2A
3 changed files with 3 additions and 3 deletions

View File

@ -8,7 +8,7 @@ jest.mock('../src/extensions', () => ({
describe('Config tests', () => {
it('checking addCoverage with PCOV on windows', async () => {
let win32: string = await coverage.addCoverage('pcov', '7.4', 'win32');
let win32: string = await coverage.addCoverage('PCOV', '7.4', 'win32');
expect(win32).toContain('add_extension pcov');
expect(win32).toContain('Remove-Extension xdebug');

2
dist/index.js vendored
View File

@ -2151,7 +2151,7 @@ exports.disableCoverage = disableCoverage;
*/
function addCoverage(coverage_driver, version, os_version) {
return __awaiter(this, void 0, void 0, function* () {
coverage_driver.toLowerCase();
coverage_driver = coverage_driver.toLowerCase();
const script = '\n' + (yield utils.stepLog('Setup Coverage', os_version));
const pipe = yield utils.suppressOutput(os_version);
switch (coverage_driver) {

View File

@ -143,7 +143,7 @@ export async function addCoverage(
version: string,
os_version: string
): Promise<string> {
coverage_driver.toLowerCase();
coverage_driver = coverage_driver.toLowerCase();
const script: string =
'\n' + (await utils.stepLog('Setup Coverage', os_version));
const pipe: string = await utils.suppressOutput(os_version);