Skip to content

Commit b6f3eb9

Browse files
authored
chore: basic CI (#9)
* chore: Go CI runs on `libevm` branch * fix: stop using `reflect.TypeFor[T]()` * chore: rename job, remove flaky tests, and clear `GOOS`+`GOARCH` * fix: PR branch was `libem` * chore: rename workflow * chore: disable flaky `accounts/keystore` test
1 parent 5429fd8 commit b6f3eb9

File tree

2 files changed

+8
-10
lines changed

2 files changed

+8
-10
lines changed

.github/workflows/go.yml

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,20 @@
1-
name: i386 linux tests
1+
name: Go
22

33
on:
44
push:
5-
branches: [ master ]
5+
branches: [ libevm ]
66
pull_request:
7-
branches: [ master ]
7+
branches: [ libevm ]
88
workflow_dispatch:
99

1010
jobs:
11-
build:
12-
runs-on: self-hosted
11+
go_test_short:
12+
runs-on: ubuntu-latest
1313
steps:
1414
- uses: actions/checkout@v2
1515
- name: Set up Go
1616
uses: actions/setup-go@v2
1717
with:
1818
go-version: 1.21.4
1919
- name: Run tests
20-
run: go test -short ./...
21-
env:
22-
GOOS: linux
23-
GOARCH: 386
20+
run: go test -short $(go list ./... | grep -Pv 'go-ethereum/(accounts/keystore|eth/downloader|miner)$')

params/config.libevm.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,8 @@ func (*Extras[C, R]) getter() (g ExtraPayloadGetter[C, R]) { return }
108108

109109
// mustBeStruct panics if `T` isn't a struct.
110110
func mustBeStruct[T any]() {
111-
if k := reflect.TypeFor[T]().Kind(); k != reflect.Struct {
111+
var x T
112+
if k := reflect.TypeOf(x).Kind(); k != reflect.Struct {
112113
panic(notStructMessage[T]())
113114
}
114115
}

0 commit comments

Comments
 (0)