Package com.heroku.api.connection

Examples of com.heroku.api.connection.Connection


     * @param username Heroku username.
     * @param password Heroku password.
     * @return An API key that can be used for subsequent API calls.
     */
    public static String obtainApiKey(String username, String password) {
        Connection tmpConn = ConnectionFactory.get();
        LoginVerification verification = tmpConn.execute(new BasicAuthLogin(username, password), null);
        return verification.getApiKey();
    }
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

TOP

Related Classes of com.heroku.api.connection.Connection

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.