Skip to content

Commit 9ed57b5

Browse files
author
Rene Glover
committed
fix unused test imports and stubbings
1 parent e552242 commit 9ed57b5

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

server/src/test/java/com/cloud/user/AccountManagerImplTest.java

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
// under the License.
1717
package com.cloud.user;
1818

19-
import static org.junit.Assert.assertThrows;
2019
import static org.mockito.ArgumentMatchers.nullable;
2120

2221
import java.net.InetAddress;
@@ -1299,12 +1298,6 @@ public void testAssertUserNotAlreadyInAccount_UserExistsInDiffAccount() {
12991298
Account newAccount = Mockito.mock(Account.class);
13001299
Mockito.when(newAccount.getId()).thenReturn(1L);
13011300

1302-
AccountVO existingAccount = Mockito.mock(AccountVO.class);
1303-
Mockito.when(existingAccount.getUuid()).thenReturn("existing-account-uuid");
1304-
Mockito.when(existingAccount.getAccountName()).thenReturn("existing-account");
1305-
1306-
Mockito.when(_accountDao.findById(1L)).thenReturn(existingAccount);
1307-
13081301
accountManagerImpl.assertUserNotAlreadyInAccount(existingUser, newAccount);
13091302
}
13101303

@@ -1343,15 +1336,8 @@ public void testAssertUserNotAlreadyInDomain_UserExistsInDiffDomain() {
13431336

13441337
AccountVO existingAccount = Mockito.mock(AccountVO.class);
13451338
Mockito.when(existingAccount.getDomainId()).thenReturn(2L);
1346-
Mockito.when(existingAccount.getUuid()).thenReturn("existing-account-uuid");
1347-
Mockito.when(existingAccount.getAccountName()).thenReturn("existing-account");
1348-
1349-
DomainVO existingDomain = Mockito.mock(DomainVO.class);
1350-
Mockito.when(existingDomain.getUuid()).thenReturn("existing-domain-uuid");
1351-
Mockito.when(existingDomain.getName()).thenReturn("existing-domain");
13521339

13531340
Mockito.when(_accountDao.findById(1L)).thenReturn(existingAccount);
1354-
Mockito.when(_domainDao.findById(1L)).thenReturn(existingDomain);
13551341

13561342
accountManagerImpl.assertUserNotAlreadyInDomain(existingUser, originalAccount);
13571343
}

0 commit comments

Comments
 (0)