# opencode_rs SDK justfile
# E2E integration testing recipes for version-pinned opencode server
set shell := ["bash", "-euo", "pipefail", "-c"]
# Integration test with bunx-provisioned pinned opencode version
[no-exit-message]
integration-test-bunx-stable:
#!/usr/bin/env bash
set -euxo pipefail
OPENCODE_BINARY=bunx \
OPENCODE_BINARY_ARGS="--yes opencode-ai@1.3.17" \
OPENCODE_INTEGRATION=1 \
cargo test -p opencode_rs --features server --test integration -- --ignored --nocapture --test-threads=1
# Quick smoke test: verify bunx-provisioned server reports correct version
[no-exit-message]
smoke-bunx-version:
#!/usr/bin/env bash
set -euxo pipefail
OPENCODE_BINARY=bunx \
OPENCODE_BINARY_ARGS="--yes opencode-ai@1.3.17" \
OPENCODE_INTEGRATION=1 \
cargo test -p opencode_rs --features server --test integration test_health_returns_pinned_version -- --ignored --nocapture
# Integration test with verbose output
[no-exit-message]
integration-test-bunx-verbose:
#!/usr/bin/env bash
set -euxo pipefail
RUST_LOG=opencode_rs=debug \
OPENCODE_BINARY=bunx \
OPENCODE_BINARY_ARGS="--yes opencode-ai@1.3.17" \
OPENCODE_INTEGRATION=1 \
cargo test -p opencode_rs --features server --test integration -- --ignored --nocapture --test-threads=1