From e08ac095690015a8c488e05251e05feb2acc57a0 Mon Sep 17 00:00:00 2001 From: Christian Niederer Date: Fri, 14 Feb 2020 21:16:59 +0100 Subject: src: add test/abort build tasks The Aliased*Array overflow check test introduced a dependency to a compiled artifact. Add this artifact to the build process in a similar fashion as test/addons and test/js-native-api do. PR-URL: https://github.com/nodejs/node/pull/31740 Reviewed-By: James M Snell Reviewed-By: Anna Henningsen Reviewed-By: David Carlier Reviewed-By: Colin Ihrig --- vcbuild.bat | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) (limited to 'vcbuild.bat') diff --git a/vcbuild.bat b/vcbuild.bat index 561eb535f2..4956a4ac2c 100644 --- a/vcbuild.bat +++ b/vcbuild.bat @@ -16,11 +16,11 @@ if /i "%1"=="/?" goto help cd %~dp0 @rem CI_* variables should be kept synchronized with the ones in Makefile -set CI_NATIVE_SUITES=addons js-native-api node-api +set CI_NATIVE_SUITES=addons js-native-api node-api abort set CI_JS_SUITES=default set CI_DOC=doctool @rem Same as the test-ci target in Makefile -set "common_test_suites=%CI_JS_SUITES% %CI_NATIVE_SUITES% %CI_DOC%&set build_addons=1&set build_js_native_api_tests=1&set build_node_api_tests=1" +set "common_test_suites=%CI_JS_SUITES% %CI_NATIVE_SUITES% %CI_DOC%&set build_addons=1&set build_js_native_api_tests=1&set build_node_api_tests=1&set build_aborts_tests=1" @rem Process arguments. set config=Release @@ -68,6 +68,7 @@ set openssl_no_asm= set doc= set extra_msbuild_args= set exit_code=0 +set build_aborts_tests= :next-arg if "%1"=="" goto args-done @@ -96,6 +97,8 @@ if /i "%1"=="test-ci-js" set test_args=%test_args% %test_ci_args% -J -p tap - if /i "%1"=="build-addons" set build_addons=1&goto arg-ok if /i "%1"=="build-js-native-api-tests" set build_js_native_api_tests=1&goto arg-ok if /i "%1"=="build-node-api-tests" set build_node_api_tests=1&goto arg-ok +if /i "%1"=="build-abort-tests" set build_abort_tests=1&goto arg-ok +if /i "%1"=="test-abort" set test_args=%test_args% abort&set build_abort_tests=1&goto arg-ok if /i "%1"=="test-addons" set test_args=%test_args% addons&set build_addons=1&goto arg-ok if /i "%1"=="test-js-native-api" set test_args=%test_args% js-native-api&set build_js_native_api_tests=1&goto arg-ok if /i "%1"=="test-node-api" set test_args=%test_args% node-api&set build_node_api_tests=1&goto arg-ok @@ -585,10 +588,10 @@ endlocal goto build-node-api-tests :build-node-api-tests -if not defined build_node_api_tests goto run-tests +if not defined build_node_api_tests goto build-abort-tests if not exist "%node_exe%" ( echo Failed to find node.exe - goto run-tests + goto build-abort-tests ) echo Building node-api :: clear @@ -601,6 +604,25 @@ set npm_config_nodedir=%~dp0 "%node_exe%" "%~dp0tools\build-addons.js" "%~dp0deps\npm\node_modules\node-gyp\bin\node-gyp.js" "%~dp0test\node-api" if errorlevel 1 exit /b 1 endlocal +goto build-abort-tests + +:build-abort-tests +if not defined build_abort_tests goto run-tests +if not exist "%node_exe%" ( + echo Failed to find node.exe + goto run-tests +) +echo Building abort +:: clear +for /d %%F in (test\abort\??_*) do ( + rd /s /q %%F +) +:: building abort +setlocal +set npm_config_nodedir=%~dp0 +"%node_exe%" "%~dp0tools\build-addons.js" "%~dp0deps\npm\node_modules\node-gyp\bin\node-gyp.js" "%~dp0test\abort" +if errorlevel 1 exit /b 1 +endlocal goto run-tests :run-tests -- cgit v1.2.1