Skip to content
Merged
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
36 changes: 36 additions & 0 deletions .github/workflows/ci-preemptive.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#!/usr/bin/env sh

set -ex

CARGO=cargo
if [ "${CROSS}" = "1" ]; then
export CARGO_NET_RETRY=5
export CARGO_NET_TIMEOUT=10

cargo install cross
CARGO=cross
fi

# If a test crashes, we want to know which one it was.
export RUST_TEST_THREADS=1
export RUST_BACKTRACE=1

# test open-coroutine-core mod
cd "${PROJECT_DIR}"/core
"${CARGO}" test --target "${TARGET}" --features preemptive
"${CARGO}" test --target "${TARGET}" --features preemptive --release

# test open-coroutine
cd "${PROJECT_DIR}"/open-coroutine
"${CARGO}" test --target "${TARGET}" --features preemptive
"${CARGO}" test --target "${TARGET}" --features preemptive --release

# test io_uring
if [ "${TARGET}" = "x86_64-unknown-linux-gnu" ]; then
cd "${PROJECT_DIR}"/core
"${CARGO}" test --target "${TARGET}" --no-default-features --features io_uring,preemptive
"${CARGO}" test --target "${TARGET}" --no-default-features --features io_uring,preemptive --release
cd "${PROJECT_DIR}"/open-coroutine
"${CARGO}" test --target "${TARGET}" --no-default-features --features io_uring,preemptive
"${CARGO}" test --target "${TARGET}" --no-default-features --features io_uring,preemptive --release
fi
36 changes: 36 additions & 0 deletions .github/workflows/ci.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#!/usr/bin/env sh

set -ex

CARGO=cargo
if [ "${CROSS}" = "1" ]; then
export CARGO_NET_RETRY=5
export CARGO_NET_TIMEOUT=10

cargo install cross
CARGO=cross
fi

# If a test crashes, we want to know which one it was.
export RUST_TEST_THREADS=1
export RUST_BACKTRACE=1

# test open-coroutine-core mod
cd "${PROJECT_DIR}"/core
"${CARGO}" test --target "${TARGET}"
"${CARGO}" test --target "${TARGET}" --release

# test open-coroutine
cd "${PROJECT_DIR}"/open-coroutine
"${CARGO}" test --target "${TARGET}"
"${CARGO}" test --target "${TARGET}" --release

# test io_uring
if [ "${TARGET}" = "x86_64-unknown-linux-gnu" ]; then
cd "${PROJECT_DIR}"/core
"${CARGO}" test --target "${TARGET}" --no-default-features --features io_uring
"${CARGO}" test --target "${TARGET}" --no-default-features --features io_uring --release
cd "${PROJECT_DIR}"/open-coroutine
"${CARGO}" test --target "${TARGET}" --no-default-features --features io_uring
"${CARGO}" test --target "${TARGET}" --no-default-features --features io_uring --release
fi
Loading
Loading