assertTrue(twitter1.equals(twitter2));
assertEquals(twitter1, twitter2);
}
public void testOAuth() throws Exception {
ConfigurationBuilder build = new ConfigurationBuilder();
String oAuthAccessToken = p.getProperty("id1.oauth.accessToken");
String oAuthAccessTokenSecret = p.getProperty("id1.oauth.accessTokenSecret");
String oAuthConsumerKey = p.getProperty("oauth.consumerKey");
String oAuthConsumerSecret = p.getProperty("oauth.consumerSecret");
build.setOAuthAccessToken(oAuthAccessToken);
build.setOAuthAccessTokenSecret(oAuthAccessTokenSecret);
build.setOAuthConsumerKey(oAuthConsumerKey);
build.setOAuthConsumerSecret(oAuthConsumerSecret);
OAuthAuthorization auth = new OAuthAuthorization(build.build());
Twitter twitter = new TwitterFactory().getInstance(auth);
twitter.verifyCredentials();
}