Commit e270622f authored by protolambda's avatar protolambda

ci: configure cannon CI job

parent 84db9a59
......@@ -59,6 +59,37 @@ commands:
pip3 install -r requirements.txt
python3 main.py "<<parameters.patterns>>"
jobs:
cannon-go-lint-and-test:
docker:
- image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest
steps:
- checkout
- check-changed:
patterns: cannon,packages/contracts-bedrock/contracts/cannon
- run:
name: prep Cannon results dir
command: mkdir -p /tmp/test-results
- run:
name: build Cannon example binaries
command: make elf # only compile ELF binaries with Go, we do not have MIPS GCC for creating the debug-dumps.
working_directory: cannon/example
- run:
name: Cannon Go lint
command: |
golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./...
working_directory: cannon
- run:
name: Cannon Go tests
command: |
gotestsum --format=standard-verbose --junitfile=/tmp/test-results/cannon.xml \
-- -parallel=8 -coverpkg=github.com/ethereum-optimism/optimism/cannon/... -coverprofile=coverage.out ./...
working_directory: cannon
- run:
name: upload Cannon coverage
command: codecov --verbose --clean --flags cannon-go-tests
- store_test_results:
path: /tmp/test-results
yarn-monorepo:
docker:
- image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest
......@@ -1191,9 +1222,6 @@ workflows:
- go-lint:
name: op-wheel-lint
module: op-wheel
- go-lint:
name: cannon-go-lint
module: cannon
- go-test:
name: op-batcher-tests
module: op-batcher
......@@ -1219,9 +1247,6 @@ workflows:
- go-test:
name: op-service-tests
module: op-service
- go-test:
name: cannon-go-tests
module: cannon
- go-e2e-test:
name: op-e2e-WS-tests
module: op-e2e
......@@ -1242,7 +1267,6 @@ workflows:
- op-challenger-lint
- op-program-lint
- op-service-lint
- cannon-go-lint
- op-batcher-tests
- op-bindings-tests
- op-chain-ops-tests
......@@ -1253,7 +1277,6 @@ workflows:
- op-service-tests
- op-e2e-WS-tests
- op-e2e-HTTP-tests
- cannon-go-tests
- docker-build:
name: op-node-docker-build
docker_file: op-node/Dockerfile
......@@ -1395,6 +1418,7 @@ workflows:
- op-challenger-docker-build
- check-generated-mocks-op-node
- check-generated-mocks-op-service
- cannon-go-lint-and-test
release:
jobs:
- hold:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment