diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 12a23ea61..944f2b2f1 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -6,7 +6,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - go_version: ["1.18.1", "1.17.6", "1.16.5"] + go_version: ["1.20", "1.19", "1.18"] steps: - uses: actions/checkout@v3 - name: Setup Go diff --git a/README.md b/README.md index ce6d3de28..8bccfa192 100644 --- a/README.md +++ b/README.md @@ -348,7 +348,7 @@ To update Testify to the latest version, use `go get -u github.com/stretchr/test Supported go versions ================== -We currently support the most recent major Go versions from 1.13 onward. +We currently support the most recent major Go versions from 1.18 onward. ------ diff --git a/assert/assertions.go b/assert/assertions.go index fe2d29754..5bd624722 100644 --- a/assert/assertions.go +++ b/assert/assertions.go @@ -91,7 +91,7 @@ func copyExportedFields(expected interface{}) interface{} { result := reflect.New(expectedType).Elem() for i := 0; i < expectedType.NumField(); i++ { field := expectedType.Field(i) - isExported := field.PkgPath == "" // should use field.IsExported() but it's not available in Go 1.16.5 + isExported := field.IsExported() if isExported { fieldValue := expectedValue.Field(i) if isNil(fieldValue) || isNil(fieldValue.Interface()) { diff --git a/go.mod b/go.mod index 3fe9bab67..bddefac03 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/stretchr/testify -go 1.13 +go 1.20 require ( github.com/davecgh/go-spew v1.1.1