diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 16a8780..203bd39 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,7 +14,7 @@ jobs: - name: Install Go uses: actions/setup-go@v2 with: - go-version: 1.15.x + go-version: 1.13.x - name: Checkout code uses: actions/checkout@v2 - name: Run linters @@ -25,7 +25,7 @@ jobs: test: strategy: matrix: - go-version: [ 1.15.x ] + go-version: [ 1.13.x ] platform: [ ubuntu-latest, macos-latest, windows-latest ] runs-on: ${{ matrix.platform }} steps: @@ -46,7 +46,7 @@ jobs: if: success() uses: actions/setup-go@v2 with: - go-version: 1.15.x + go-version: 1.13.x - name: Checkout code uses: actions/checkout@v2 - name: Calc coverage diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ff3af42..fe9d592 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -18,7 +18,7 @@ jobs: name: Set up Go uses: actions/setup-go@v2 with: - go-version: 1.15 + go-version: 1.13 - name: Cache Go modules uses: actions/cache@v1 diff --git a/go.mod b/go.mod index 5eb3c79..dbb77b8 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/csueiras/reinforcer -go 1.15 +go 1.13 require ( github.com/dave/jennifer v1.4.1 diff --git a/internal/generator/generator_test.go b/internal/generator/generator_test.go index 3184256..9ff7958 100644 --- a/internal/generator/generator_test.go +++ b/internal/generator/generator_test.go @@ -517,7 +517,7 @@ func loadInterface(t *testing.T, filesCode map[string]input) []*generator.FileCo }, } exported := packagestest.Export(t, packagestest.GOPATH, mods) - t.Cleanup(exported.Cleanup) + defer exported.Cleanup() l := loader.NewLoader(func(cfg *packages.Config, patterns ...string) ([]*packages.Package, error) { exported.Config.Mode = cfg.Mode diff --git a/internal/loader/loader_test.go b/internal/loader/loader_test.go index 963f841..300afb2 100644 --- a/internal/loader/loader_test.go +++ b/internal/loader/loader_test.go @@ -22,7 +22,7 @@ type Service interface { } `, }}}) - t.Cleanup(exported.Cleanup) + defer exported.Cleanup() l := loader.NewLoader(func(cfg *packages.Config, patterns ...string) ([]*packages.Package, error) { exported.Config.Mode = cfg.Mode @@ -60,7 +60,7 @@ type NotAnInterface struct { } `, }}}) - t.Cleanup(exported.Cleanup) + defer exported.Cleanup() t.Run("RegEx", func(t *testing.T) { l := loader.NewLoader(func(cfg *packages.Config, patterns ...string) ([]*packages.Package, error) {