Skip to content
This repository has been archived by the owner on Jan 9, 2025. It is now read-only.

Commit

Permalink
feat: add ef-tests to CI (#755)
Browse files Browse the repository at this point in the history
## Pull request type

<!-- Please try to limit your pull request to one type,
submit multiple pull requests if needed. -->

Please check the type of change your PR introduces:

- [ ] Bugfix
- [x] Feature
- [ ] Code style update (formatting, renaming)
- [ ] Refactoring (no functional changes, no api changes)
- [ ] Build related changes
- [ ] Documentation content changes
- [ ] Other (please describe):

## What is the current behavior?

The current kakarot changes that are pushed are not tested against the
current set of passing ef-tests.

Resolves #730 

## What is the new behavior?

- All new Kakarot changes are tested against ef-tests


We have the following flow:
- build kakarot for the current proposed change
- create a katana dump for the change via RPC
- run ef-tests against this dump

---------

Co-authored-by: Harsh Bajpai <[email protected]>
  • Loading branch information
bajpai244 and Harsh Bajpai authored Oct 11, 2023
1 parent 7c1cd2c commit f5d013f
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 2 deletions.
1 change: 1 addition & 0 deletions .github/actionlint.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
self-hosted-runner:
labels:
- ubuntu-latest-16-cores
- ubuntu-latest-32-cores
33 changes: 33 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,13 @@ jobs:
- name: Compile all the cairo files
run: make build

# Upload artifacts
- name: Uploads Kakarot build artifacts
uses: actions/upload-artifact@v3
with:
name: kakarot-build
path: ./build

tests:
runs-on: ubuntu-latest-16-cores
env:
Expand Down Expand Up @@ -109,6 +116,32 @@ jobs:
path: ./coverage/
name: coverage

ef-tests:
runs-on: ubuntu-latest-32-cores
needs: build
steps:
- name: Checkout ef-tests
uses: actions/checkout@v3
with:
repository: kkrt-labs/ef-tests
- name: Rust cache
uses: Swatinem/rust-cache@v2
with:
cache-on-failure: "true"
- name: setup
run: make setup
- uses: taiki-e/install-action@nextest

- name: Download Kakarot build artifacts
uses: actions/download-artifact@v3
with:
name: kakarot-build
path: ./lib/kakarot/build

# run tests
- name: run tests
run: cargo test -p ef-testing --features ef-tests -- --nocapture

resources:
runs-on: ubuntu-latest
needs: tests
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ coverage/*
blockhashes.json
deployed_addresses.json

# thoth relateds stuff
# thoth relateds stuff
output-callgraph/*
build/*
docs/callgraphs/*
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ test: build-sol deploy
poetry run pytest tests/integration tests/src -m "not EFTests" --log-cli-level=INFO -n logical
poetry run pytest tests/end_to_end

test-no-log: build-sol deploy
test-no-log: build-sol deploy
poetry run pytest tests/integration tests/src -m "not EFTests" -n logical
poetry run pytest tests/end_to_end

Expand Down

0 comments on commit f5d013f

Please sign in to comment.