Skip to content

Commit

Permalink
test: added katana to github workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
ICavlek committed Aug 29, 2024
1 parent 2dbcb43 commit cd13825
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
11 changes: 11 additions & 0 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,17 @@ jobs:
- uses: Swatinem/rust-cache@v2
- run: cargo test --features skip-zero-root-validation

test-katana:
if: ${{ !startsWith(github.head_ref, 'dependabot/') }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- run: cd .. && git clone https://github.com/dojoengine/dojo
- run: cd ../dojo && git reset --hard v1.0.0-alpha.7 && cargo run --bin katana -- --host 127.0.0.1 -p 5050 --disable-fee &
- run: sleep 500 && cargo test -- --ignored

check:
if: startsWith(github.head_ref, 'dependabot/')
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion tests/common/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ pub async fn get_ctx(url: &str) -> Option<Context> {
root: Felt::try_new(root).unwrap(),
};
let state = Arc::new(RwLock::new(state));
let server = serve(&url, "127.0.0.1:0", state.clone()).await.ok()?;
let server = serve(url, "127.0.0.1:0", state.clone()).await.ok()?;
tracing::info!(port = server.port(), "test server is up");

let url = format!("http://localhost:{}/rpc", server.port());
Expand Down

0 comments on commit cd13825

Please sign in to comment.