File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -1568,16 +1568,16 @@ func (s *ServiceTestSuite) TestCreate() {
15681568 Return (nil ).Once ()
15691569
15701570 actualError := h .service .Create (context .Background (), appeals )
1571- time .Sleep (time .Millisecond )
15721571
15731572 s .Nil (actualError )
15741573 s .Equal (expectedResult , appeals )
1574+
1575+ time .Sleep (time .Millisecond )
15751576 })
15761577
15771578 s .Run ("additional appeal creation" , func () {
15781579 s .Run ("should use the overridding policy" , func () {
15791580 h := newServiceTestHelper ()
1580- defer h .assertExpectations (s .T ())
15811581 input := & domain.Appeal {
15821582 ResourceID : uuid .New ().String (),
15831583@@ -1666,11 +1666,13 @@ func (s *ServiceTestSuite) TestCreate() {
16661666 h .mockProviderService .EXPECT ().GrantAccess (mock .Anything , mock .Anything ).Return (nil ).Once ()
16671667
16681668 err := h .service .Create (context .Background (), []* domain.Appeal {input }, appeal .CreateWithAdditionalAppeal ())
1669- time .Sleep (time .Millisecond )
16701669
16711670 s .NoError (err )
16721671 s .Equal ("test-approval" , input .Approvals [0 ].Name )
16731672 s .Equal (expectedPermissions , input .Permissions )
1673+
1674+ time .Sleep (time .Millisecond )
1675+ h .assertExpectations (s .T ())
16741676 })
16751677 })
16761678}
You can’t perform that action at this time.
0 commit comments