Skip to content

Commit

Permalink
fix(test): policy test temp dir creation (#645)
Browse files Browse the repository at this point in the history
* fix(test): policy test temp dir creation

* fix(test): increase timeout of test in makefile
  • Loading branch information
revitteth authored Jun 19, 2024
1 parent d5e17e6 commit 2d2712a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -149,10 +149,10 @@ db-tools:

## test: run unit tests with a 100s timeout
test:
$(GOTEST) --timeout 100s
$(GOTEST) --timeout 200s

test3:
$(GOTEST) --timeout 100s -tags $(BUILD_TAGS),erigon3
$(GOTEST) --timeout 200s -tags $(BUILD_TAGS),erigon3

## test-integration: run integration tests with a 30m timeout
test-integration:
Expand Down
6 changes: 1 addition & 5 deletions zk/txpool/policy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,7 @@ func newTestACLDB(tb testing.TB, dir string) kv.RwDB {
tb.Helper()

if dir == "" {
dir = fmt.Sprintf("/tmp/acl-db-temp_%v", time.Now().UTC().Format(time.RFC3339Nano))

if err := os.Mkdir(dir, 0775); err != nil {
tb.Fatal(err)
}
dir = tb.TempDir()
}

state, err := OpenACLDB(context.Background(), dir)
Expand Down

0 comments on commit 2d2712a

Please sign in to comment.