* GitHub Actions: npm test is failing Windows tests on M1 Macs
`npm test` is running and failing Windows `find-visualstudio` tests on an M1 Mac!!!
These tests are not being run or not failing on Intel Macs.
* Only run "Find Visual Studio" tests on Windows
* Update test/test-find-visualstudio.js
Co-authored-by: Christian Clauss <cclauss@me.com>
---------
Co-authored-by: Stefan Stojanovic <StefanStojanovic@users.noreply.github.com>
Detect visual studio installation using the VSSetup module and
Get-VSSetupInstance method. It works even in systems with the
Constrained language mode of PowerShell.
BREAKING CHANGE: the `Gyp` class exported is now created using
ECMAScript classes and therefore might have small differences to classes
that were previously created with `util.inherits`.
BREAKING CHANGE: All internal functions have been coverted to return
promises and no longer accept callbacks. This is not a breaking change
for users but may be breaking to consumers of `node-gyp` if you are
requiring internal functions directly.
* migrate from tap to mocha
After make-fetch-happen update GitHub Actions started failing. Migrating
from tap to mocha testing framework for GitHub Action stability.
* write custom test reporter for more verbose output
Implemented a simple custom mocha test reporter to replace the default
one. Made test report more developer friendly.
In addition:
* moved module.exports to the bottom
* no single-line if statements
* no if statements without a {
* const for requires
* array declarations get spaces inside [ ]
* 'use strict' in all .js files
PR-URL: https://github.com/nodejs/node-gyp/pull/1794
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: João Reis <reis@janeasystems.com>