Skip to content

Commit 7770279

Browse files
joaocgreisBethGriggs
authored andcommitted
build,win: add test-ci-native and test-ci-js
Backport-PR-URL: #30727 PR-URL: #30724 Refs: nodejs/build#1996 Reviewed-By: Rod Vagg <rod@vagg.org> Reviewed-By: Sam Roberts <vieuxtech@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
1 parent eac6143 commit 7770279

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

Makefile

+1
Original file line numberDiff line numberDiff line change
@@ -395,6 +395,7 @@ test-all: test-build test/gc/build/Release/binding.node ## Run everything in tes
395395
test-all-valgrind: test-build
396396
$(PYTHON) tools/test.py --mode=debug,release --valgrind
397397

398+
# CI_* variables should be kept synchronized with the ones in vcbuild.bat
398399
CI_NATIVE_SUITES ?= addons addons-napi
399400
CI_ASYNC_HOOKS := async-hooks
400401
CI_JS_SUITES ?= default

vcbuild.bat

+12-2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,14 @@ if /i "%1"=="/?" goto help
1111

1212
cd %~dp0
1313

14+
@rem CI_* variables should be kept synchronized with the ones in Makefile
15+
set CI_NATIVE_SUITES=addons addons-napi
16+
set CI_ASYNC_HOOKS=async-hooks
17+
set CI_JS_SUITES=default
18+
set CI_DOC=doctool
19+
@rem Same as the test-ci target in Makefile
20+
set "common_test_suites=%CI_ASYNC_HOOKS% %CI_JS_SUITES% %CI_NATIVE_SUITES% %CI_DOC% known_issues&set build_addons=1&set build_addons_napi=1"
21+
1422
@rem Process arguments.
1523
set config=Release
1624
set target=Build
@@ -44,10 +52,8 @@ set enable_static=
4452
set build_addons_napi=
4553
set test_node_inspect=
4654
set test_check_deopts=
47-
set js_test_suites=default async-hooks known_issues
4855
set v8_test_options=
4956
set v8_build_options=
50-
set "common_test_suites=%js_test_suites% doctool addons addons-napi&set build_addons=1&set build_addons_napi=1"
5157
set http2_debug=
5258
set nghttp2_debug=
5359
set link_module=
@@ -74,6 +80,8 @@ if /i "%1"=="noperfctr" set noperfctr=1&goto arg-ok
7480
if /i "%1"=="licensertf" set licensertf=1&goto arg-ok
7581
if /i "%1"=="test" set test_args=%test_args% -J %common_test_suites%&set lint_cpp=1&set lint_js=1&goto arg-ok
7682
if /i "%1"=="test-ci" set test_args=%test_args% %test_ci_args% -p tap --logfile test.tap %common_test_suites%&set cctest_args=%cctest_args% --gtest_output=tap:cctest.tap&goto arg-ok
83+
if /i "%1"=="test-ci-native" set test_args=%test_args% %test_ci_args% -J -p tap --logfile test.tap %CI_NATIVE_SUITES% %CI_DOC%&set build_addons=1&set build_addons_napi=1&set cctest_args=%cctest_args% --gtest_output=tap:cctest.tap&goto arg-ok
84+
if /i "%1"=="test-ci-js" set test_args=%test_args% %test_ci_args% -J -p tap --logfile test.tap %CI_ASYNC_HOOKS% %CI_JS_SUITES% known_issues&set skip_cctest=1&goto arg-ok
7785
if /i "%1"=="test-addons" set test_args=%test_args% addons&set build_addons=1&goto arg-ok
7886
if /i "%1"=="test-addons-napi" set test_args=%test_args% addons-napi&set build_addons_napi=1&goto arg-ok
7987
if /i "%1"=="test-simple" set test_args=%test_args% sequential parallel -J&goto arg-ok
@@ -474,9 +482,11 @@ if errorlevel 1 goto exit
474482
if "%test_args%"=="" goto test-v8
475483
if "%config%"=="Debug" set test_args=--mode=debug %test_args%
476484
if "%config%"=="Release" set test_args=--mode=release %test_args%
485+
if defined skip_cctest goto run-test-py
477486
if not exist %config%\cctest.exe goto run-test-py
478487
echo running 'cctest %cctest_args%'
479488
"%config%\cctest" %cctest_args%
489+
:run-test-py
480490
REM when building a static library there's no binary to run tests
481491
if defined enable_static goto test-v8
482492
call :run-python tools\test.py %test_args%

0 commit comments

Comments
 (0)