Skip to content

Commit 457cd79

Browse files
committed
[ci] Enhancement: Test Integration Flag
1 parent ba498f1 commit 457cd79

File tree

6 files changed

+32
-15
lines changed

6 files changed

+32
-15
lines changed

.github/workflows/catloop.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ jobs:
6161
--branch origin/$branch_name \
6262
--libos $LIBOS \
6363
--debug \
64-
--test-unit --test-system all --delay 2 --enable-nfs \
64+
--test-unit --test-integration --test-system all \
65+
--delay 2 --enable-nfs \
6566
--server-addr $SERVER_ADDR \
6667
--client-addr $CLIENT_ADDR
6768
- name: Archive Logs
@@ -109,7 +110,8 @@ jobs:
109110
--repository demikernel \
110111
--branch origin/$branch_name \
111112
--libos $LIBOS \
112-
--test-unit --test-system all --delay 2 --enable-nfs \
113+
--test-unit --test-integration --test-system all \
114+
--delay 2 --enable-nfs \
113115
--server-addr $SERVER_ADDR \
114116
--client-addr $CLIENT_ADDR \
115117
--connection-string "${{ secrets.AZURE_STORAGE_CONNECTION_STRING }}" \

.github/workflows/catmem.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ jobs:
6161
--branch origin/$branch_name \
6262
--libos $LIBOS \
6363
--debug \
64-
--test-unit --test-system all --delay 2 --enable-nfs \
64+
--test-unit --test-integration --test-system all \
65+
--delay 2 --enable-nfs \
6566
--server-addr $SERVER_ADDR \
6667
--client-addr $CLIENT_ADDR
6768
- name: Archive Logs
@@ -109,7 +110,8 @@ jobs:
109110
--repository demikernel \
110111
--branch origin/$branch_name \
111112
--libos $LIBOS \
112-
--test-unit --test-system all --delay 2 --enable-nfs \
113+
--test-unit --test-integration --test-system all \
114+
--delay 2 --enable-nfs \
113115
--server-addr $SERVER_ADDR \
114116
--client-addr $CLIENT_ADDR \
115117
--connection-string "${{ secrets.AZURE_STORAGE_CONNECTION_STRING }}" \

.github/workflows/catnap.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ jobs:
6161
--branch origin/$branch_name \
6262
--libos $LIBOS \
6363
--debug \
64-
--test-unit --test-system all --delay 2 \
64+
--test-unit --test-integration --test-system all \
65+
--delay 2 \
6566
--server-addr $SERVER_ADDR \
6667
--client-addr $CLIENT_ADDR
6768
- name: Archive Logs
@@ -109,7 +110,8 @@ jobs:
109110
--repository demikernel \
110111
--branch origin/$branch_name \
111112
--libos $LIBOS \
112-
--test-unit --test-system all --delay 2 \
113+
--test-unit --test-integration --test-system all \
114+
--delay 2 \
113115
--server-addr $SERVER_ADDR \
114116
--client-addr $CLIENT_ADDR \
115117
--connection-string "${{ secrets.AZURE_STORAGE_CONNECTION_STRING }}" \

.github/workflows/catnip.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ jobs:
6161
--branch origin/$branch_name \
6262
--debug \
6363
--libos $LIBOS \
64-
--test-unit --test-system all --delay 2 \
64+
--test-unit --test-integration --test-system all \
65+
--delay 2 \
6566
--server-addr $SERVER_ADDR \
6667
--client-addr $CLIENT_ADDR
6768
- name: Archive Logs
@@ -109,7 +110,8 @@ jobs:
109110
--repository demikernel \
110111
--branch origin/$branch_name \
111112
--libos $LIBOS \
112-
--test-unit --test-system all --delay 2 \
113+
--test-unit --test-integration --test-system all \
114+
--delay 2 \
113115
--server-addr $SERVER_ADDR \
114116
--client-addr $CLIENT_ADDR \
115117
--connection-string "${{ secrets.AZURE_STORAGE_CONNECTION_STRING }}" \

.github/workflows/catpowder.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ jobs:
6161
--branch origin/$branch_name \
6262
--debug \
6363
--libos $LIBOS \
64-
--test-unit --test-system all --delay 2 \
64+
--test-unit --test-integration --test-system all \
65+
--delay 2 \
6566
--server-addr $SERVER_ADDR \
6667
--client-addr $CLIENT_ADDR
6768
- name: Archive Logs
@@ -109,7 +110,8 @@ jobs:
109110
--repository demikernel \
110111
--branch origin/$branch_name \
111112
--libos $LIBOS \
112-
--test-unit --test-system all --delay 2 \
113+
--test-unit --test-integration --test-system all \
114+
--delay 2 \
113115
--server-addr $SERVER_ADDR \
114116
--client-addr $CLIENT_ADDR \
115117
--connection-string "${{ secrets.AZURE_STORAGE_CONNECTION_STRING }}" \

tools/demikernel_ci.py

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@
1717

1818
# Runs the CI pipeline.
1919
def run_pipeline(
20-
log_directory: str,
21-
repository: str, branch: str, libos: str, is_debug: bool, server: str, client: str,
22-
test_unit: bool, test_system: str, server_addr: str, client_addr: str, delay: float, config_path: str,
20+
log_directory: str, repository: str, branch: str, libos: str, is_debug:
21+
bool, server: str, client: str, test_unit: bool, test_integration: bool,
22+
test_system: str, server_addr: str, client_addr: str, delay: float, config_path: str,
2323
output_dir: str, enable_nfs: bool, install_prefix: str) -> int:
2424
is_sudo: bool = True if libos == "catnip" or libos == "catpowder" or libos == "catloop" else False
2525
status: dict[str, bool] = {}
@@ -67,6 +67,10 @@ def run_pipeline(
6767
status["unit_tests"] = True
6868
status["unit_tests"] &= factory.unit_test(test_name="test-unit-rust").execute()
6969
status["unit_tests"] &= factory.unit_test(test_name="test-unit-c").execute()
70+
71+
# STEP 4: Run integration tests.
72+
if test_integration:
73+
if status["checkout"] and status["compile"]:
7074
if libos == "catnap" or libos == "catloop":
7175
status["integration_tests"] = factory.integration_test().execute()
7276
elif libos == "catmem":
@@ -76,7 +80,7 @@ def run_pipeline(
7680
status["integration_tests"] = factory.integration_test("push-wait-async").execute()
7781
status["integration_tests"] = factory.integration_test("pop-wait-async").execute()
7882

79-
# STEP 4: Run system tests.
83+
# STEP 5: Run system tests.
8084
if test_system and config["platform"] == "linux":
8185
if status["checkout"] and status["compile"]:
8286
ci_map = read_yaml(libos)
@@ -240,6 +244,8 @@ def read_args() -> argparse.Namespace:
240244
# Test options.
241245
parser.add_argument("--test-unit", action='store_true',
242246
required=False, help="run unit tests")
247+
parser.add_argument("--test-integration", action='store_true',
248+
required=False, help="run integration tests")
243249
parser.add_argument("--test-system", type=str,
244250
required=False, help="run system tests")
245251
parser.add_argument("--test-redis", action='store_true', required=False, help="run redis tests")
@@ -283,6 +289,7 @@ def main():
283289

284290
# Extract test options.
285291
test_unit: bool = args.test_unit
292+
test_integration: bool = args.test_integration
286293
test_system: str = args.test_system
287294
test_redis: bool = args.test_redis
288295
server_addr: str = args.server_addr
@@ -309,7 +316,7 @@ def main():
309316
mkdir(log_directory)
310317

311318
status: dict = run_pipeline(log_directory, repository, branch, libos, is_debug, server,
312-
client, test_unit, test_system, server_addr,
319+
client, test_unit, test_integration, test_system, server_addr,
313320
client_addr, delay, config_path, output_dir, enable_nfs, install_prefix)
314321

315322
if test_redis:

0 commit comments

Comments
 (0)