feat: add chain-initiator tool to use mainnet snapshot in localnet #10303
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Golang CI | |
on: [pull_request] | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up Go 1.19 | |
uses: actions/setup-go@v3 | |
with: | |
go-version: 1.19 | |
- uses: actions/checkout@v3 | |
- name: Build | |
run: make install | |
- name: Test | |
run: | | |
go test -v ./... -coverprofile=coverage.txt -covermode=atomic -coverpkg $(go list ./... | grep -v test | tr "\n" ",") | |
excludelist="$(find ./ -type f -name '*.go' | xargs grep -l 'DONTCOVER')" | |
for filename in ${excludelist}; do | |
filename=$(echo $filename | sed 's/^../github.com\/Sifchain\/sifnode/g') | |
echo "Excluding ${filename} from coverage report..." | |
sed -i.bak "/$(echo $filename | sed 's/\//\\\//g')/d" coverage.txt | |
done | |
- name: Upload coverage report | |
uses: codecov/codecov-action@v3 | |
with: | |
file: ./coverage.txt | |
verbose: true |