mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-17 16:28:06 +03:00
Ladybird+Meta: Add ctest to run WPT in the Integration configuration
By running ctest -C Integration -R WPT, you can run WPT. Adding just -C Integration will run all other tests *and* the WPT test. Also add support for ./Meta/serenity.sh test lagom WPT to serenity.sh
This commit is contained in:
parent
8e605fb0f9
commit
99499a6fae
Notes:
sideshowbarker
2024-07-17 08:25:15 +09:00
Author: https://github.com/ADKaster Commit: https://github.com/SerenityOS/serenity/commit/99499a6fae Pull-request: https://github.com/SerenityOS/serenity/pull/20668
@ -219,5 +219,14 @@ if (BUILD_TESTING)
|
|||||||
NAME LibWeb
|
NAME LibWeb
|
||||||
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/../bin/headless-browser --run-tests ${SERENITY_SOURCE_DIR}/Tests/LibWeb
|
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/../bin/headless-browser --run-tests ${SERENITY_SOURCE_DIR}/Tests/LibWeb
|
||||||
)
|
)
|
||||||
set_tests_properties(LibWeb PROPERTIES ENVIRONMENT QT_QPA_PLATFORM=offscreen)
|
add_test(
|
||||||
|
NAME WPT
|
||||||
|
CONFIGURATIONS Integration
|
||||||
|
COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/../Tests/LibWeb/WPT/run.sh
|
||||||
|
)
|
||||||
|
set_tests_properties(LibWeb WPT PROPERTIES
|
||||||
|
DEPENDS ladybird
|
||||||
|
ENVIRONMENT QT_QPA_PLATFORM=offscreen
|
||||||
|
ENVIRONMENT "SERENITY_SOURCE_DIR=${SERENITY_SOURCE_DIR}"
|
||||||
|
)
|
||||||
endif()
|
endif()
|
||||||
|
@ -256,12 +256,14 @@ ensure_target() {
|
|||||||
|
|
||||||
run_tests() {
|
run_tests() {
|
||||||
local TEST_NAME="$1"
|
local TEST_NAME="$1"
|
||||||
export CTEST_OUTPUT_ON_FAILURE=1
|
local CTEST_ARGS=("--output-on-failure" "--test-dir" "$BUILD_DIR")
|
||||||
if [ -n "$TEST_NAME" ]; then
|
if [ -n "$TEST_NAME" ]; then
|
||||||
( cd "$BUILD_DIR" && ctest -R "$TEST_NAME" )
|
if [ "$TEST_NAME" = "WPT" ]; then
|
||||||
else
|
CTEST_ARGS+=("-C" "Integration")
|
||||||
( cd "$BUILD_DIR" && ctest )
|
fi
|
||||||
|
CTEST_ARGS+=("-R" "$TEST_NAME")
|
||||||
fi
|
fi
|
||||||
|
ctest "${CTEST_ARGS[@]}"
|
||||||
}
|
}
|
||||||
|
|
||||||
build_target() {
|
build_target() {
|
||||||
|
Loading…
Reference in New Issue
Block a user