Skip to content

Commit

Permalink
undo minor changes
Browse files Browse the repository at this point in the history
  • Loading branch information
atye committed Feb 14, 2023
1 parent 3bfc34d commit 869f3aa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions internal/powerflex/storage_pool_cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,5 +87,6 @@ func (c *StoragePoolCache) GetStoragePoolNameByID(ctx context.Context, tokenGett
}

c.cache.Add(id, pool.Name)

return pool.Name, nil
}
4 changes: 1 addition & 3 deletions internal/powerflex/storage_pool_cache_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -267,10 +267,8 @@ func TestStoragePoolCache_GetStoragePoolNameByID(t *testing.T) {
})
defer powerFlexSvr.Close()

client := newPowerFlexClient(t, powerFlexSvr.URL)

// Attempt to create new storage pool with cache size
_, gotErr := powerflex.NewStoragePoolCache(client, 0)
_, gotErr := powerflex.NewStoragePoolCache(newPowerFlexClient(t, powerFlexSvr.URL), 0)
wantErr := fmt.Errorf("cache size must be at least one")
if gotErr.Error() != wantErr.Error() {
t.Errorf("New Storage Pool Cache: got err = %v, want: %v", gotErr, wantErr)
Expand Down

0 comments on commit 869f3aa

Please sign in to comment.