@Test
public void testExecuteWithEmptyPassword() {

    ReflectionTestUtils.setField(createAccountCmd, "password", "");
    try {
        createAccountCmd.execute();
        Assert.fail("should throw exception for a empty password");
    } catch (ServerApiException e) {
        Assert.assertEquals(ApiErrorCode.PARAM_ERROR, e.getErrorCode());
        Assert.assertEquals("Empty passwords are not allowed", e.getMessage());
    }
    Mockito.verify(accountService, Mockito.never()).createUserAccount(null, null, null, null, null, null, null, accountType, domainId, null, null, null, null);
}