From b00483627ec9b220b58c50d9a46268d2e9b54657 Mon Sep 17 00:00:00 2001 From: AmudaPalani Date: Fri, 29 May 2020 13:05:03 -0500 Subject: [PATCH] Updated functional test with bug fix for https://github.com/Optum/dce/issues/344 --- tests/acceptance/update_lease_status_test.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/acceptance/update_lease_status_test.go b/tests/acceptance/update_lease_status_test.go index acc59f0a9..5b52218a3 100644 --- a/tests/acceptance/update_lease_status_test.go +++ b/tests/acceptance/update_lease_status_test.go @@ -253,11 +253,16 @@ func TestUpdateLeaseStatusLambda(t *testing.T) { err = json.Unmarshal(result.Payload, &resp) require.Nil(t, err) - // Check lease status is active + // Check lease status is inactive lease, err := dbSvc.GetLease(accountID, "user") require.Nil(t, err) require.Equal(t, db.LeaseStatus("Inactive"), lease.LeaseStatus) require.Equal(t, db.LeaseStatusReason("Expired"), lease.LeaseStatusReason) + + // Check account status is updated to NotReady + account, err := dbSvc.GetAccount(accountID) + require.Nil(t, err) + require.Equal(t, db.NotReady, account.AccountStatus) }) t.Run("Exceeded lease budget result in Inactive lease with reason OverBudget.", func(t *testing.T) {