Package com.heroku.api.request.user

Examples of com.heroku.api.request.user.UserInfo


    /**
     * Information for the current user.
     * @return
     */
    public User getUserInfo() {
        return connection.execute(new UserInfo(), apiKey);
    }
View Full Code Here


    String apiKey = IntegrationTestConfig.CONFIG.getDefaultUser().getApiKey();

    @Test(timeOut = 10000)
    @SuppressWarnings("unchecked")
    public void asyncTests() {
        Future<User> jsonArrayResponseFuture = connection.executeAsync(new UserInfo(), apiKey);
        User user = (User) jsonArrayResponseFuture.get(Duration.fromTimeUnit(10L, TimeUnit.SECONDS)).get();
        assertEquals(user.getEmail(), IntegrationTestConfig.CONFIG.getDefaultUser().getUsername());
    }
View Full Code Here

    @Test(retryAnalyzer = InternalServerErrorAnalyzer.class)
    public void testUserInfo() {
        IntegrationTestConfig.TestUser testUser = CONFIG.getDefaultUser();
        Connection userInfoConnection = new HttpClientConnection();
        UserInfo userInfo = new UserInfo();
        User user = userInfoConnection.execute(userInfo, testUser.getApiKey());
        assertEquals(user.getEmail(), testUser.getUsername());
    }
View Full Code Here

    String apiKey = IntegrationTestConfig.CONFIG.getDefaultUser().getApiKey();

    @Test
    public void asyncTests() throws ExecutionException, TimeoutException, InterruptedException {
        Future<User> jsonArrayResponseFuture = connection.executeAsync(new UserInfo(), apiKey);
        User user = (User) jsonArrayResponseFuture.get(10, TimeUnit.SECONDS);
        assertEquals(user.getEmail(), IntegrationTestConfig.CONFIG.getDefaultUser().getUsername());
    }
View Full Code Here

TOP

Related Classes of com.heroku.api.request.user.UserInfo

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.