mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-02-02 18:44:49 -05:00
only use test action in license integration test
This commit is contained in:
parent
bff4351839
commit
3d50869ed6
@ -18,28 +18,15 @@ import (
|
|||||||
func TestQuotaCheckIntegration(t *testing.T) {
|
func TestQuotaCheckIntegration(t *testing.T) {
|
||||||
testCases := map[string]struct {
|
testCases := map[string]struct {
|
||||||
license string
|
license string
|
||||||
action Action
|
|
||||||
wantQuota int
|
wantQuota int
|
||||||
wantError bool
|
wantError bool
|
||||||
}{
|
}{
|
||||||
"OSS license has quota 8": {
|
"OSS license has quota 8": {
|
||||||
license: CommunityLicense,
|
license: CommunityLicense,
|
||||||
action: test,
|
|
||||||
wantQuota: 8,
|
|
||||||
},
|
|
||||||
"OSS license missing action": {
|
|
||||||
license: CommunityLicense,
|
|
||||||
action: "",
|
|
||||||
wantQuota: 8,
|
wantQuota: 8,
|
||||||
},
|
},
|
||||||
"Empty license assumes community": {
|
"Empty license assumes community": {
|
||||||
license: "",
|
license: "",
|
||||||
action: test,
|
|
||||||
wantQuota: 8,
|
|
||||||
},
|
|
||||||
"Empty request": {
|
|
||||||
license: "",
|
|
||||||
action: "",
|
|
||||||
wantQuota: 8,
|
wantQuota: 8,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@ -51,7 +38,7 @@ func TestQuotaCheckIntegration(t *testing.T) {
|
|||||||
client := NewClient()
|
client := NewClient()
|
||||||
|
|
||||||
req := QuotaCheckRequest{
|
req := QuotaCheckRequest{
|
||||||
Action: tc.action,
|
Action: test,
|
||||||
License: tc.license,
|
License: tc.license,
|
||||||
}
|
}
|
||||||
resp, err := client.QuotaCheck(context.Background(), req)
|
resp, err := client.QuotaCheck(context.Background(), req)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user