Skip to content

Commit

Permalink
fix: fix an error in CI (#302)
Browse files Browse the repository at this point in the history
* fix clippy

Signed-off-by: lzzzt <[email protected]>

* ci: fix a ci error

.github/workflows/ci.sh: 42: [: nightly: unexpected operator

Signed-off-by: lzzzt <[email protected]>

fix: fix an error in tests/fs_symlink.rs

Signed-off-by: lzzzt <[email protected]>

---------

Signed-off-by: lzzzt <[email protected]>
  • Loading branch information
Lzzzzzt authored Sep 15, 2024
1 parent d8855e9 commit bb873b0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ if [ "${NO_RUN}" != "1" ] && [ "${NO_RUN}" != "true" ]; then
"${CARGO}" test --target "${TARGET}" --release
fi

if [ "${CHANNEL}" == "nightly" ] && ([ "${TARGET}" = "x86_64-unknown-linux-gnu" ] || [ "${TARGET}" = "i686-unknown-linux-gnu" ]); then
if [ "${CHANNEL}" = "nightly" ] && ([ "${TARGET}" = "x86_64-unknown-linux-gnu" ] || [ "${TARGET}" = "i686-unknown-linux-gnu" ]); then
"${CARGO}" test --target "${TARGET}" --all-features
"${CARGO}" test --target "${TARGET}" --all-features --release
fi
Expand All @@ -53,7 +53,7 @@ if [ "${NO_RUN}" != "1" ] && [ "${NO_RUN}" != "true" ]; then
"${CARGO}" test --target "${TARGET}" --no-default-features --features hyper
"${CARGO}" test --target "${TARGET}" --no-default-features --features hyper --release

if [ "${CHANNEL}" == "nightly" ]; then
if [ "${CHANNEL}" = "nightly" ]; then
"${CARGO}" test --target "${TARGET}" --all-features
"${CARGO}" test --target "${TARGET}" --all-features --release
fi
Expand Down
4 changes: 3 additions & 1 deletion monoio/src/blocking.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,9 @@ pub enum BlockingStrategy {
}

/// `spawn_blocking` is used for executing a task(without async) with heavy computation or blocking
/// io. To used it, users may initialize a thread pool and attach it on creating runtime.
/// io.
///
/// To used it, users may initialize a thread pool and attach it on creating runtime.
/// Users can also set `BlockingStrategy` for a runtime when there is no thread pool.
/// WARNING: DO NOT USE THIS FOR ASYNC TASK! Async tasks will not be executed but only built the
/// future!
Expand Down
4 changes: 2 additions & 2 deletions monoio/tests/fs_symlink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ async fn create_symlink() {
.await
.unwrap();

let content = monoio::fs::read(dst_file_path).await.unwrap();
let content = monoio::fs::read(&dst_file_path).await.unwrap();
assert_eq!(content, TEST_PAYLOAD);
assert(dst_file_path.is_symlink());
assert!(dst_file_path.is_symlink());
}

0 comments on commit bb873b0

Please sign in to comment.