actions: fix test-importer workflow (#410)
* actions: fix test-importer workflow * update gitignore
This commit is contained in:
parent
cc6b5d04f2
commit
8789a04998
34
.github/workflows/test.yml
vendored
34
.github/workflows/test.yml
vendored
@ -193,20 +193,20 @@ jobs:
|
|||||||
file: ./coverage.txt
|
file: ./coverage.txt
|
||||||
fail_ci_if_error: true
|
fail_ci_if_error: true
|
||||||
if: "env.GIT_DIFF != ''"
|
if: "env.GIT_DIFF != ''"
|
||||||
# TODO: remove tmp dir to fix this
|
|
||||||
# test-importer:
|
test-importer:
|
||||||
# runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
# timeout-minutes: 10
|
timeout-minutes: 10
|
||||||
# steps:
|
steps:
|
||||||
# - uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
# - uses: technote-space/get-diff-action@v1
|
- uses: technote-space/get-diff-action@v1
|
||||||
# id: git_diff
|
id: git_diff
|
||||||
# with:
|
with:
|
||||||
# SUFFIX_FILTER: |
|
SUFFIX_FILTER: |
|
||||||
# .go
|
.go
|
||||||
# .mod
|
.mod
|
||||||
# .sum
|
.sum
|
||||||
# - name: importer-test
|
- name: test-importer
|
||||||
# run: |
|
run: |
|
||||||
# make test-import
|
make test-import
|
||||||
# if: "env.GIT_DIFF != ''"
|
if: "env.GIT_DIFF != ''"
|
||||||
|
1
.gitignore
vendored
1
.gitignore
vendored
@ -33,6 +33,7 @@ golangci-lint
|
|||||||
coverage.txt
|
coverage.txt
|
||||||
*.out
|
*.out
|
||||||
sim_log_file
|
sim_log_file
|
||||||
|
importer/tmp
|
||||||
|
|
||||||
# Vagrant
|
# Vagrant
|
||||||
.vagrant/
|
.vagrant/
|
||||||
|
1
Makefile
1
Makefile
@ -150,6 +150,7 @@ test-race:
|
|||||||
test-import:
|
test-import:
|
||||||
@go test ./importer -v --vet=off --run=TestImportBlocks --datadir tmp \
|
@go test ./importer -v --vet=off --run=TestImportBlocks --datadir tmp \
|
||||||
--blockchain blockchain --timeout=10m
|
--blockchain blockchain --timeout=10m
|
||||||
|
rm -rf importer/tmp
|
||||||
|
|
||||||
test-rpc:
|
test-rpc:
|
||||||
./scripts/integration-test-all.sh -q 1 -z 1 -s 2
|
./scripts/integration-test-all.sh -q 1 -z 1 -s 2
|
||||||
|
@ -207,7 +207,10 @@ func TestImportBlocks(t *testing.T) {
|
|||||||
blockchainInput, err := os.Open(flagBlockchain)
|
blockchainInput, err := os.Open(flagBlockchain)
|
||||||
require.Nil(t, err)
|
require.Nil(t, err)
|
||||||
|
|
||||||
defer require.NoError(t, blockchainInput.Close())
|
defer func() {
|
||||||
|
err := blockchainInput.Close()
|
||||||
|
require.NoError(t, err)
|
||||||
|
}()
|
||||||
|
|
||||||
// ethereum mainnet config
|
// ethereum mainnet config
|
||||||
chainContext := core.NewChainContext()
|
chainContext := core.NewChainContext()
|
||||||
|
Loading…
Reference in New Issue
Block a user