Skip to content

Conversation

netsirius
Copy link
Collaborator

This pull request adds a comprehensive multi-node integration test for the River contract, improves dependency management, and updates the way the getrandom crate is included to ensure compatibility and deduplication. The most significant change is the addition of an integration test that launches multiple nodes, deploys a contract, and checks for state consistency and message propagation across the network.

Integration Testing

  • Added a new file contracts/room-contract/tests/integration_tests.rs containing an async test that launches a gateway and three nodes, deploys the River contract, subscribes all nodes, sends messages from each node, and verifies state consistency and message propagation across the network. This test also collects diagnostics and performs detailed error reporting for debugging distributed state issues.

Dependency Management

  • Moved the getrandom dependency in contracts/room-contract/Cargo.toml from a local explicit version to using the workspace version, ensuring deduplication and consistency across the project.
  • Added several new dev dependencies to contracts/room-contract/Cargo.toml, including anyhow, freenet, once_cell, tempfile, testresult, tokio, tokio-tungstenite, tracing, and tracing-subscriber, to support robust integration testing and diagnostics.

Cross-Project Dependency Update

  • Added getrandom = { version = "0.2.16", features = ["js"] } to the root Cargo.toml to ensure the correct version and features are available for all workspace members, helping prevent version conflicts and supporting WASM targets.

@netsirius netsirius force-pushed the add-river-integration-tests branch from 6de1c23 to c8cf01e Compare August 26, 2025 21:39
netsirius and others added 6 commits September 4, 2025 20:16
# Conflicts:
#	contracts/room-contract/Cargo.toml
- Resolved conflicts in .github/workflows/build.yml: kept integration tests from branch, updated build command from main
- Resolved conflicts in contracts/room-contract/Cargo.toml: updated river-common to river-core dependency
- Updated all river_common references to river_core in test files

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
@netsirius netsirius force-pushed the add-river-integration-tests branch from 59ac65b to 5cf8c78 Compare September 4, 2025 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant