Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,10 @@ build:x86_64-qnx --platforms=@score_bazel_platforms//:x86_64-qnx-sdp_8.0.0-posix
build:x86_64-qnx --extra_toolchains=@score_qcc_x86_64_toolchain//:x86_64-qnx-sdp_8.0.0
build:x86_64-qnx --extra_toolchains=@score_toolchains_rust//toolchains/ferrocene:ferrocene_x86_64_pc_nto_qnx800
build:x86_64-qnx --extra_toolchains=@score_qnx_x86_64_ifs_toolchain//:ifs-x86_64-qnx-sdp_8.0.0
test:x86_64-qnx --run_under=@score_qnx_unit_tests//src:run_under_qnx
test:x86_64-qnx --test_tag_filters=-skip_local # see https://github.com/eclipse-score/lifecycle/issues/272
test:x86_64-qnx --test_lang_filters=cc,rust
test:x86_64-qnx --define config=x86_64-qnx
# test:x86_64-qnx --run_under=@score_qnx_unit_tests//src:run_under_qnx
# test:x86_64-qnx --test_tag_filters=-skip_local # see https://github.com/eclipse-score/lifecycle/issues/272
# test:x86_64-qnx --test_lang_filters=cc,rust

# Target configuration for CPU:AArch64|OS:QNX build (do not use it in case of system toolchains!)
build:arm64-qnx --config=stub
Expand Down
18 changes: 14 additions & 4 deletions tests/utils/bazel/integration.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -81,25 +81,35 @@ def integration_test(
"//tests/utils/testing_utils",
],
data = kwargs.pop("data", []) + [":environment"] + select({
"//config:host": [],
"//conditions:default": ["//tests/utils/environments:test_environment"],
"//config:x86_64-linux": [
"//tests/utils/environments/x86_64-linux",
],
"//config:x86_64-qnx": [
"//tests/utils/environments/x86_64-qnx:qemu_config.json",
"//tests/utils/environments/x86_64-qnx:qemu_image",
],
"//conditions:default": [],
}),
args = kwargs.pop("args", []) + [
"--score-test-binary-path=$(locations :environment)",
"--score-test-remote-directory={}/tests/{}".format(install_prefix, name),
] + select({
"//config:x86_64-linux": [
"--docker-image-bootstrap=$(location //tests/utils/environments:test_environment)",
"--docker-image-bootstrap=$(location //tests/utils/environments/x86_64-linux)",
"--docker-image=score_itf_examples:latest",
],
"//config:x86_64-qnx": [
"--qemu-config=$(location //tests/utils/environments/x86_64-qnx:qemu_config.json)",
"--qemu-image=$(location //tests/utils/environments/x86_64-qnx:qemu_image)",
],
"//config:host": [
"--local-dir=/tmp/score_itf_host/{}".format(name),
],
"//conditions:default": [],
}),
plugins = ["//tests/utils/plugins:integration_plugin"] + select({
"//config:x86_64-linux": ["@score_itf//score/itf/plugins:docker_plugin"],
"//config:x86_64-qnx": ["@score_itf//score/itf/plugins/qemu"],
"//config:x86_64-qnx": ["@score_itf//score/itf/plugins:qemu_plugin"],
"//config:host": ["//tests/utils/plugins:localhost_plugin"],
"//conditions:default": [],
}),
Expand Down
22 changes: 0 additions & 22 deletions tests/utils/environments/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -15,25 +15,3 @@ exports_files(
["ecu_logging_config.json"],
visibility = ["//tests/utils/environments:__subpackages__"],
)

# Empty target for native builds
filegroup(
name = "empty_target",
srcs = [],
visibility = [
"//examples:__subpackages__",
"//tests:__subpackages__",
],
)

alias(
name = "test_environment",
actual = select({
"//config:x86_64-linux": "//tests/utils/environments/x86_64-linux",
"//conditions:default": ":empty_target",
}),
visibility = [
"//examples:__subpackages__",
"//tests:__subpackages__",
],
)
33 changes: 33 additions & 0 deletions tests/utils/environments/x86_64-qnx/BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# *******************************************************************************
# Copyright (c) 2025 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
#
# This program and the accompanying materials are made available under the
# terms of the Apache License Version 2.0 which is available at
# https://www.apache.org/licenses/LICENSE-2.0
#
# SPDX-License-Identifier: Apache-2.0
# *******************************************************************************

load("@rules_pkg//pkg:mappings.bzl", "pkg_files")
load("@score_rules_imagefs//rules/qnx:ifs.bzl", "qnx_ifs")

pkg_files(
name = "qnx_config",
srcs = ["qcrypto.conf"],
prefix = "/etc",
)

exports_files(
["qemu_config.json"],
visibility = ["//tests:__subpackages__"],
)

qnx_ifs(
name = "qemu_image",
build_file = ":init.build",
srcs = [":qnx_config"],
visibility = ["//tests:__subpackages__"],
)
Loading
Loading