summaryrefslogtreecommitdiff
path: root/test/end-to-end/with_serve_test_runner.py
diff options
context:
space:
mode:
authorPaul Cristian Sarbu <paul.cristian.sarbu@huawei.com>2023-11-15 15:37:10 +0100
committerPaul Cristian Sarbu <paul.cristian.sarbu@huawei.com>2023-11-16 15:19:07 +0100
commit04486312bdba9b610edbd71d23b5f4a428e04a40 (patch)
tree45b71484b077f9c9aad7a83901061bf664225265 /test/end-to-end/with_serve_test_runner.py
parent4a7517b4c638118abcff6bc406171bf9566be2fc (diff)
downloadjustbuild-04486312bdba9b610edbd71d23b5f4a428e04a40.tar.gz
test: Check that serve service works in compatible mode
Added compatibility envariable to the with_serve rule, guarded tests using --fetch-absent such that they run only in native mode, and made all serve-service tests aware of the compatibility flag.
Diffstat (limited to 'test/end-to-end/with_serve_test_runner.py')
-rwxr-xr-xtest/end-to-end/with_serve_test_runner.py12
1 files changed, 10 insertions, 2 deletions
diff --git a/test/end-to-end/with_serve_test_runner.py b/test/end-to-end/with_serve_test_runner.py
index 2782b7ed..25723a2c 100755
--- a/test/end-to-end/with_serve_test_runner.py
+++ b/test/end-to-end/with_serve_test_runner.py
@@ -75,6 +75,8 @@ SERVE_DIR = os.path.realpath("serve")
os.makedirs(SERVE_DIR, exist_ok=True)
SERVE_LBR = os.path.join(SERVE_DIR, "build-root")
+compatible = json.loads(sys.argv[1])
+
remote_proc = None
# start just execute as remote service
@@ -96,6 +98,9 @@ remote_cmd = [
"--plain-log",
]
+if compatible:
+ remote_cmd.append("--compatible")
+
remotestdout = open("remotestdout", "w")
remotestderr = open("remotestderr", "w")
remote_proc = subprocess.Popen(
@@ -123,7 +128,8 @@ serve_config: Json = {
"plain": True
},
"execution endpoint": {
- "address": g_REMOTE_EXECUTION_ADDRESS
+ "address": g_REMOTE_EXECUTION_ADDRESS,
+ "compatible": compatible
},
"remote service": {
"info file": SERVE_INFO
@@ -219,7 +225,9 @@ ENV = dict(
SERVE_LBR=SERVE_LBR, # expose the serve build root to the test env
**repos_env)
-if "COMPATIBLE" in ENV:
+if compatible:
+ ENV["COMPATIBLE"] = "YES"
+elif "COMPATIBLE" in ENV:
del ENV["COMPATIBLE"]
for k in ["TLS_CA_CERT", "TLS_CLIENT_CERT", "TLS_CLIENT_KEY"]: