@@ -828,55 +828,47 @@ jobs:
828828 when : always
829829
830830 go-test :
831- parameters :
832- module :
833- description : Go Module Name
834- type : string
835- uses_artifacts :
836- description : Uses contract artifacts
837- type : boolean
838- default : false
839- docker :
840- - image : <<pipeline.parameters.ci_builder_image>>
841- resource_class : xlarge
842- circleci_ip_ranges : true
831+ machine : true
832+ resource_class : ethereum-optimism/latitude-1
843833 steps :
844834 - checkout
845- - restore_cache :
846- name : Restore Go modules cache
847- key : gomod-{{ checksum "go.sum" }}
848- - restore_cache :
849- name : Restore Go build cache
850- keys :
851- - golang-build-cache-test-<<parameters.module>>-{{ checksum "go.sum" }}
852- - golang-build-cache-test-
853- - when :
854- condition : <<parameters.uses_artifacts>>
855- steps :
856- - attach_workspace : { at: "." }
857- - run :
858- name : Install components
859- command : |
860- go version
861- go install gotest.tools/[email protected] 862- - run :
863- name : prep results dir
864- command : mkdir -p /tmp/test-results && mkdir -p /tmp/testlogs
835+ - attach_workspace :
836+ at : " ."
865837 - run :
866838 name : run tests
867839 command : |
868- ENABLE_ANVIL=true SEPOLIA_RPC_URL="https://ci-sepolia-l1.optimism.io" gotestsum --format=testname --junitfile=/tmp/test-results/<<parameters.module>>.xml --jsonfile=/tmp/testlogs/log.json \
869- -- -parallel=8 -coverpkg=github.com/ethereum-optimism/optimism/... -coverprofile=coverage.out ./...
870- working_directory : <<parameters.module>>
871- - save_cache :
872- name : Save Go build cache
873- key : golang-build-cache-test-<<parameters.module>>-{{ checksum "go.sum" }}
874- paths :
875- - " /root/.cache/go-build"
840+ mkdir -p ./tmp/test-results && mkdir -p ./tmp/testlogs
841+
842+ packages=(
843+ op-batcher
844+ op-chain-ops
845+ op-node
846+ op-proposer
847+ op-challenger
848+ op-dispute-mon
849+ op-conductor
850+ op-program
851+ op-service
852+ op-supervisor
853+ packages/contracts-bedrock/scripts/checks/semver-natspec
854+ )
855+ formatted_packages=""
856+ for package in "${packages[@]}"; do
857+ formatted_packages="$formatted_packages ./$package/..."
858+ done
859+
860+ export ENABLE_ANVIL=true
861+ export SEPOLIA_RPC_URL="https://ci-sepolia-l1-archive.optimism.io"
862+
863+ gotestsum --format=testname \
864+ --junitfile=./tmp/test-results/results.xml \
865+ --jsonfile=./tmp/testlogs/log.json \
866+ -- -coverpkg=github.com/ethereum-optimism/optimism/... \
867+ -coverprofile=coverage.out $formatted_packages
876868 - store_test_results :
877- path : /tmp/test-results
869+ path : . /tmp/test-results
878870 - store_artifacts :
879- path : /tmp/testlogs
871+ path : . /tmp/testlogs
880872 when : always
881873
882874 go-e2e-test :
@@ -1355,30 +1347,8 @@ workflows:
13551347 uses_artifacts : true
13561348 requires : ["go-mod-download", "contracts-bedrock-build"]
13571349 - go-test :
1358- name : <<matrix.module>>-tests
1350+ name : go-test-all
13591351 requires :
1360- - go-mod-download
1361- matrix :
1362- parameters :
1363- module :
1364- - op-batcher
1365- - op-node
1366- - op-proposer
1367- - op-challenger
1368- - op-dispute-mon
1369- - op-conductor
1370- - op-program
1371- - op-service
1372- - op-supervisor
1373- - go-test :
1374- name : semver-natspec-tests
1375- module : packages/contracts-bedrock/scripts/checks/semver-natspec
1376- - go-test :
1377- name : op-chain-ops-tests
1378- module : op-chain-ops
1379- uses_artifacts : true
1380- requires :
1381- - go-mod-download
13821352 - contracts-bedrock-build
13831353 - go-test-kurtosis :
13841354 name : op-chain-ops-integration
@@ -1405,9 +1375,7 @@ workflows:
14051375 requires :
14061376 - contracts-bedrock-build
14071377 - cannon-prestate
1408- - op-program-compat :
1409- requires :
1410- - op-program-tests
1378+ - op-program-compat
14111379 - bedrock-go-tests :
14121380 requires :
14131381 - go-mod-download
@@ -1417,18 +1385,8 @@ workflows:
14171385 - check-generated-mocks-op-node
14181386 - check-generated-mocks-op-service
14191387 - go-mod-download
1420- - op-batcher-tests
1421- - op-chain-ops-tests
14221388 - op-chain-ops-integration
1423- - op-node-tests
1424- - op-proposer-tests
1425- - op-challenger-tests
1426- - op-dispute-mon-tests
1427- - op-conductor-tests
1428- - op-program-tests
14291389 - op-program-compat
1430- - op-service-tests
1431- - op-supervisor-tests
14321390 - op-e2e-HTTP-tests
14331391 - op-e2e-fault-proof-tests
14341392 - op-e2e-action-tests
@@ -1438,6 +1396,7 @@ workflows:
14381396 - op-program-docker-build
14391397 - op-supervisor-docker-build
14401398 - proofs-tools-docker-build
1399+ - go-test-all
14411400 - docker-build :
14421401 name : <<matrix.docker_name>>-docker-build
14431402 docker_tags : <<pipeline.git.revision>>,<<pipeline.git.branch>>
0 commit comments