Skip to content

Commit

Permalink
RELTEC-11853: added "data" as optional field to keys-datastructure
Browse files Browse the repository at this point in the history
make "key" field optional
  • Loading branch information
mplushnikov committed Jun 13, 2024
1 parent fe49140 commit e72dded
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 17 deletions.
11 changes: 6 additions & 5 deletions api/generated_apimodel.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 4 additions & 8 deletions api/openapi-v3-spec.json
Original file line number Diff line number Diff line change
Expand Up @@ -3029,16 +3029,12 @@
}
},
"RepositoryConfigurationAccessKeyDto": {
"required": [
"key"
],
"properties": {
"key": {
"type": "string",
"enum": [
"DEPLOYMENT",
"QUMULO"
]
"type": "string"
},
"data": {
"type": "string"
},
"permission": {
"type": "string",
Expand Down
6 changes: 3 additions & 3 deletions internal/service/repositories/repositories_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func createRepositoryDto() openapi.RepositoryDto {
Configuration: &openapi.RepositoryConfigurationDto{
AccessKeys: []openapi.RepositoryConfigurationAccessKeyDto{
{
Key: "KEY",
Key: ptr("KEY"),
Permission: ptr("REPO_WRITE"),
},
},
Expand Down Expand Up @@ -111,7 +111,7 @@ func TestPatchRepository_ReplaceAll(t *testing.T) {
Configuration: &openapi.RepositoryConfigurationDto{
AccessKeys: []openapi.RepositoryConfigurationAccessKeyDto{
{
Key: "DEPLOYMENT",
Key: ptr("DEPLOYMENT"),
Permission: ptr("REPO_READ"),
},
},
Expand Down Expand Up @@ -147,7 +147,7 @@ func TestPatchRepository_ReplaceAll(t *testing.T) {
Configuration: &openapi.RepositoryConfigurationDto{
AccessKeys: []openapi.RepositoryConfigurationAccessKeyDto{
{
Key: "DEPLOYMENT",
Key: ptr("DEPLOYMENT"),
Permission: ptr("REPO_READ"),
},
},
Expand Down
2 changes: 1 addition & 1 deletion test/acceptance/util_dtos_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ func tstRepository() openapi.RepositoryDto {
Configuration: &openapi.RepositoryConfigurationDto{
AccessKeys: []openapi.RepositoryConfigurationAccessKeyDto{
{
Key: "KEY",
Key: p("KEY"),
Permission: p("REPO_WRITE"),
},
},
Expand Down

0 comments on commit e72dded

Please sign in to comment.