Skip to content

Commit

Permalink
avoid expensive tests
Browse files Browse the repository at this point in the history
  • Loading branch information
skyscrapr committed Jul 13, 2023
1 parent 3e930a6 commit 36d79b6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions openai/finetune_data_source_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@ import (
)

func TestAccFineTuneDataSource(t *testing.T) {
t.Skip("Cost associated with test")
resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t) },
PreCheck: func() { testAccOpenAI(t); testAccPreCheck(t) },
ProtoV6ProviderFactories: testAccProtoV6ProviderFactories,
Steps: []resource.TestStep{
// Read testing
Expand Down
2 changes: 1 addition & 1 deletion openai/provider_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ func testAccPreCheck(t *testing.T) {

func testAccOpenAI(t *testing.T) {
// Use this to skip tests that might take a long time or cost too much
if os.Getenv("TF_ACC_OPENAI") != "" {
if os.Getenv("TF_ACC_OPENAI") == "" {
t.Skipf("env var TF_ACC_OPENAI not set. Skipping acceptance test")
}
}

0 comments on commit 36d79b6

Please sign in to comment.