Skip to content

Commit

Permalink
Update provider client type
Browse files Browse the repository at this point in the history
  • Loading branch information
Liam Galvin committed Feb 18, 2019
1 parent 912066d commit 1d95684
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions codeowners/resource_file_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func TestAccResourceFile(t *testing.T) {
}

func testAccCheckFileDestroy(s *terraform.State) error {
client := testAccProvider.Meta().(*github.Client)
config := testAccProvider.Meta().(*providerConfiguration)

for _, rs := range s.RootModule().Resources {
if rs.Type != "codeowners_repository_file" {
Expand All @@ -72,7 +72,7 @@ func testAccCheckFileDestroy(s *terraform.State) error {
owner, name := parts[0], parts[1]

ctx := context.Background()
_, _, response, err := client.Repositories.GetContents(ctx, owner, name, codeownersPath, &github.RepositoryContentGetOptions{})
_, _, response, err := config.client.Repositories.GetContents(ctx, owner, name, codeownersPath, &github.RepositoryContentGetOptions{})
if err != nil || response.StatusCode >= 500 {
return err
}
Expand Down

0 comments on commit 1d95684

Please sign in to comment.