Skip to content

Commit

Permalink
Add scheduled status (#4668)
Browse files Browse the repository at this point in the history
* Add scheduled status

* Add test

* Improve log output
  • Loading branch information
DanielMieg authored Nov 13, 2023
1 parent 2a98742 commit 6e2ecef
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/abaputils/manageGitRepositoryUtils.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ func PollEntity(repositoryName string, connectionDetails ConnectionDetailsHTTP,
return status, err
}
status = pullEntity.Status
log.Entry().WithField("StatusCode", responseStatus).Info("Status: " + pullEntity.StatusDescription)
if pullEntity.Status != "R" {
log.Entry().WithField("StatusCode", responseStatus).Info("Status: " + pullEntity.Status + " - " + pullEntity.StatusDescription)
if pullEntity.Status != "R" && pullEntity.Status != "Q" {

PrintLogs(repositoryName, connectionDetails, client)
break
Expand Down
1 change: 1 addition & 0 deletions pkg/abaputils/manageGitRepositoryUtils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ func TestPollEntity(t *testing.T) {
logResultError,
`{"d" : { "status" : "E" } }`,
`{"d" : { "status" : "R" } }`,
`{"d" : { "status" : "Q" } }`,
},
Token: "myToken",
StatusCode: 200,
Expand Down

0 comments on commit 6e2ecef

Please sign in to comment.