Skip to content

Commit

Permalink
Update live_test steps and ./resouces (#279)
Browse files Browse the repository at this point in the history
* remove obselete testcase TestGroupsWithAuthFile from resources

* Update live_test.yml

Co-authored-by: JerryPei1997 <729683758@qq,com>
  • Loading branch information
JerryPei1997 and JerryPei1997 authored Apr 30, 2020
1 parent 2195ed9 commit 96378ae
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 21 deletions.
3 changes: 1 addition & 2 deletions .azure-pipelines/steps/live_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ steps:
displayName: 'Live Test'
env:
AZURE_AUTH_LOCATION: $(AZURE_AUTH_LOCATION)
AZURE_BASE_GROUP_NAME: $(AZURE_BASE_GROUP_NAME)
AZURE_CLIENT_ID: $(AZURE_CLIENT_ID)
AZURE_CLIENT_SECRET: $(AZURE_CLIENT_SECRET)
Expand All @@ -25,4 +24,4 @@ steps:
AZURE_USE_DEVICEFLOW: $(AZURE_USE_DEVICEFLOW)
AZURE_STORAGE_ACCOUNT_NAME: $(AZURE_STORAGE_ACCOUNT_NAME)
AZURE_STORAGE_ACCOUNT_GROUP_NAME: $(AZURE_STORAGE_ACCOUNT_GROUP_NAME)
19 changes: 0 additions & 19 deletions resources/resources_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,22 +63,3 @@ func TestGroups(t *testing.T) {
}
t.Logf("created group: %s\n", config.GroupName())
}

// TODO -- remove or change this test since we are not using the travis CI now
func TestGroupsWithAuthFile(t *testing.T) {
if _, isCi := os.LookupEnv(CiKeyName); isCi == true {
t.Skipf("skipping auth file test in CI")
}
groupName := config.GenerateGroupName("resource-groups-authfile")
config.SetGroupName(groupName) // TODO: don't rely on globals
ctx, cancel := context.WithTimeout(context.Background(), 300*time.Second)
defer cancel()
defer Cleanup(ctx)

var err error
_, err = CreateGroupWithAuthFile(ctx, config.GroupName())
if err != nil {
t.Fatalf("failed to create group: %+v", err)
}
t.Logf("created group with auth file: %s\n", config.GroupName())
}

0 comments on commit 96378ae

Please sign in to comment.