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
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- uses: actions/setup-python@v7
with:
python-version: '3.12'
- run: pip install ipymini
- run: pip install ipymini pyzmq
- run: cargo fmt --check
- run: cargo clippy --all-targets -- -D warnings
- run: cargo test
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ let msg = iopub.recv().await?;
cargo test
```

The integration tests run against a real kernel. Install it first with `pip install ipymini`. Set `ZMTPMINI_TEST_PYTHON` to choose which Python runs it.
The integration tests run against a real kernel and pyzmq peers. Install them first with `pip install ipymini pyzmq`. Set `ZMTPMINI_TEST_PYTHON` to choose which Python runs them.

## Release

Expand Down
7 changes: 6 additions & 1 deletion tests/server.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
//! The accepting-side story against unmodified pyzmq DEALER, SUB, and REQ peers.

use std::process::Command;
use std::time::Duration;
use tokio::net::TcpListener;
use zmtpmini::{Incoming, Peer};

Expand Down Expand Up @@ -40,6 +41,10 @@ async fn pyzmq_peer_story() {
writer.send(message).await.unwrap();
};

tokio::join!(router_story, publisher_story, reply_story);
if tokio::time::timeout(Duration::from_secs(30), async { tokio::join!(router_story, publisher_story, reply_story) }).await.is_err() {
let _ = child.kill();
let _ = child.wait();
panic!("pyzmq peer timed out");
}
assert!(child.wait().unwrap().success());
}