Fix watchexec-events tests

This commit is contained in:
Félix Saparelli 2024-04-21 00:36:59 +12:00
parent 22b58a66ab
commit e1cef25d7f
No known key found for this signature in database
5 changed files with 17 additions and 38 deletions

View File

@ -68,9 +68,11 @@ jobs:
key: ${{ runner.os }}-target-stable-${{ hashFiles('**/Cargo.lock') }} key: ${{ runner.os }}-target-stable-${{ hashFiles('**/Cargo.lock') }}
- name: Run test suite - name: Run test suite
run: cargo test ${{ env.flags }} run: cargo test
- name: Run watchexec-events integration tests
run: cargo test -p watchexec-events -F serde
- name: Check that CLI runs - name: Check that CLI runs
run: cargo run ${{ env.flags }} -p watchexec-cli -- -1 echo run: cargo run -p watchexec-cli -- -1 echo
- name: Install coreutils on mac - name: Install coreutils on mac
if: ${{ matrix.platform == 'macos' }} if: ${{ matrix.platform == 'macos' }}
@ -89,7 +91,7 @@ jobs:
shell: bash shell: bash
- name: Generate manpage - name: Generate manpage
run: cargo run ${{ env.flags }} -p watchexec-cli -- --manual > doc/watchexec.1 run: cargo run -p watchexec-cli -- --manual > doc/watchexec.1
- name: Check that manpage is up to date - name: Check that manpage is up to date
run: git diff --exit-code -- doc/ run: git diff --exit-code -- doc/

43
Cargo.lock generated
View File

@ -4013,8 +4013,8 @@ dependencies = [
"tokio", "tokio",
"tracing", "tracing",
"tracing-subscriber", "tracing-subscriber",
"watchexec-events 3.0.0", "watchexec-events",
"watchexec-signals 3.0.0", "watchexec-signals",
"watchexec-supervisor", "watchexec-supervisor",
] ]
@ -4064,24 +4064,12 @@ dependencies = [
"tracing-test", "tracing-test",
"uuid", "uuid",
"watchexec", "watchexec",
"watchexec-events 3.0.0", "watchexec-events",
"watchexec-filterer-globset", "watchexec-filterer-globset",
"watchexec-signals 3.0.0", "watchexec-signals",
"which", "which",
] ]
[[package]]
name = "watchexec-events"
version = "2.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8fa905a7f327bfdda78b9c06831d3180a419b7b722bd1ef779ac13ff2ab69df0"
dependencies = [
"nix 0.27.1",
"notify",
"serde",
"watchexec-signals 2.1.0",
]
[[package]] [[package]]
name = "watchexec-events" name = "watchexec-events"
version = "3.0.0" version = "3.0.0"
@ -4091,8 +4079,7 @@ dependencies = [
"serde", "serde",
"serde_json", "serde_json",
"snapbox", "snapbox",
"watchexec-events 2.0.1", "watchexec-signals",
"watchexec-signals 3.0.0",
] ]
[[package]] [[package]]
@ -4105,7 +4092,7 @@ dependencies = [
"tracing", "tracing",
"tracing-subscriber", "tracing-subscriber",
"watchexec", "watchexec",
"watchexec-events 3.0.0", "watchexec-events",
"watchexec-filterer-ignore", "watchexec-filterer-ignore",
] ]
@ -4122,18 +4109,8 @@ dependencies = [
"tracing", "tracing",
"tracing-subscriber", "tracing-subscriber",
"watchexec", "watchexec",
"watchexec-events 3.0.0", "watchexec-events",
"watchexec-signals 3.0.0", "watchexec-signals",
]
[[package]]
name = "watchexec-signals"
version = "2.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "af0a778522cf0fc2fa8a8f1380e32893208cb2e7fd33e64de8bd81a00a2a7838"
dependencies = [
"nix 0.27.1",
"serde",
] ]
[[package]] [[package]]
@ -4156,8 +4133,8 @@ dependencies = [
"process-wrap", "process-wrap",
"tokio", "tokio",
"tracing", "tracing",
"watchexec-events 3.0.0", "watchexec-events",
"watchexec-signals 3.0.0", "watchexec-signals",
] ]
[[package]] [[package]]

View File

@ -19,7 +19,6 @@ tempfile = "3.8.0"
tracing-test = "0.2.4" tracing-test = "0.2.4"
rand = "0.8" rand = "0.8"
uuid = "1.5.0" uuid = "1.5.0"
watchexec-events = "2.0.1"
[profile.release] [profile.release]
lto = true lto = true

View File

@ -33,7 +33,6 @@ version = "0.28.0"
features = ["signal"] features = ["signal"]
[dev-dependencies] [dev-dependencies]
watchexec-events = { workspace = true, features = ["serde"] }
snapbox = "0.5.9" snapbox = "0.5.9"
serde_json = "1.0.107" serde_json = "1.0.107"

View File

@ -1,3 +1,5 @@
#![cfg(feature = "serde")]
use std::num::{NonZeroI32, NonZeroI64}; use std::num::{NonZeroI32, NonZeroI64};
use snapbox::{assert_eq, file}; use snapbox::{assert_eq, file};