From 6e2db3dc2585a02275c6b84e69aec1557a81189a Mon Sep 17 00:00:00 2001 From: Rob Ede Date: Mon, 15 Nov 2021 00:02:27 +0000 Subject: [PATCH] run io-uring tests on circle ci --- .circleci/config.yml | 22 ++++++++++++++++++++++ actix-rt/src/system.rs | 8 ++++---- 2 files changed, 26 insertions(+), 4 deletions(-) create mode 100644 .circleci/config.yml diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 00000000..6ad50a8a --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,22 @@ +version: 2.1 + +jobs: + test-io-uring-features: + machine: + image: ubuntu-2004:202107-02 + resource_class: large + environment: + CI: '1' + CARGO_INCREMENTAL: '0' + RUST_BACKTRACE: '1' + steps: + - checkout + - run: uname -a + - run: apt-get update; apt-get install -y liburing-dev + - run: cargo test -p=actix-rt --features=io-uring + - run: cargo test -p=actix-server --features=io-uring + +workflows: + test: + jobs: + - test-io-uring-features diff --git a/actix-rt/src/system.rs b/actix-rt/src/system.rs index e32d6209..6c089dda 100644 --- a/actix-rt/src/system.rs +++ b/actix-rt/src/system.rs @@ -175,9 +175,9 @@ impl System { } } -#[cfg(not(feature = "io-uring"))] /// Runner that keeps a [System]'s event loop alive until stop message is received. -#[must_use = "A SystemRunner does nothing unless `run` is called."] +#[cfg(not(feature = "io-uring"))] +#[must_use = "A SystemRunner does nothing unless `run` or `block_on` is called."] #[derive(Debug)] pub struct SystemRunner { rt: crate::runtime::Runtime, @@ -216,9 +216,9 @@ impl SystemRunner { } } -#[cfg(feature = "io-uring")] /// Runner that keeps a [System]'s event loop alive until stop message is received. -#[must_use = "A SystemRunner does nothing unless `run` is called."] +#[cfg(feature = "io-uring")] +#[must_use = "A SystemRunner does nothing unless `run` or `block_on` is called."] #[derive(Debug)] pub struct SystemRunner;