From bc6261d4445b39f0b3fdc8eacc1c9e72661aa4cd Mon Sep 17 00:00:00 2001 From: Tobias Trabelsi Date: Sat, 6 Aug 2022 16:47:00 +0200 Subject: [PATCH] fixed tests incremented version number --- Makefile | 2 +- README.md | 2 +- examples/provider.tf | 2 +- gitea/provider_test.go | 12 +++++------- 4 files changed, 8 insertions(+), 10 deletions(-) diff --git a/Makefile b/Makefile index e2a15fa..fea4cf6 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ GOFMT_FILES?=$$(find . -name '*.go' |grep -v vendor) GOFMT ?= gofmt -s -VERSION = 0.7.0 +VERSION = 0.7.1 test: fmt-check go test -i $(TEST) || exit 1 diff --git a/README.md b/README.md index 3f7670a..93402c7 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ terraform { required_providers { gitea = { source = "Lerentis/gitea" - version = "0.7.0" + version = "0.7.1" } } } diff --git a/examples/provider.tf b/examples/provider.tf index 0d34bb4..65f23dd 100644 --- a/examples/provider.tf +++ b/examples/provider.tf @@ -2,7 +2,7 @@ terraform { required_providers { gitea = { source = "terraform.local/lerentis/gitea" - version = "0.7.0" + version = "0.7.1" } } } diff --git a/gitea/provider_test.go b/gitea/provider_test.go index 5c703d2..64c65d5 100644 --- a/gitea/provider_test.go +++ b/gitea/provider_test.go @@ -5,29 +5,27 @@ import ( "testing" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" - "github.com/hashicorp/terraform-plugin-sdk/v2/terraform" ) -var testAccProviders map[string]terraform.ResourceProvider +var testAccProviders map[string]*schema.Provider var testAccProvider *schema.Provider func init() { - testAccProvider = Provider().(*schema.Provider) - testAccProviders = map[string]terraform.ResourceProvider{ + testAccProvider = Provider() + testAccProviders = map[string]*schema.Provider{ "gitea": testAccProvider, } } func TestProvider(t *testing.T) { - if err := Provider().(*schema.Provider).InternalValidate(); err != nil { + if err := Provider().InternalValidate(); err != nil { t.Fatalf("err: %s", err) } } func TestProvider_impl(t *testing.T) { - var _ terraform.ResourceProvider = Provider() + var _ *schema.Provider = Provider() } - func testAccPreCheck(t *testing.T) { if v := os.Getenv("GITEA_TOKEN"); v == "" { t.Fatal("GITEA_TOKEN must be set for acceptance tests")