Used OAuthConfig when possible instead of bunch of Strings
This commit is contained in:
1 parent
8f0760664f
commit
8eb2062e95
5 files changed
+21
-22
No files matched your search
@@ -10,17 +10,14 @@ public class OAuthConfigTest
|
||||
@Test
|
||||
public void shouldReturnDefaultValuesIfNotSet()
|
||||
{
|
||||
OAuthConfig config = new OAuthConfig();
|
||||
OAuthConfig config = new OAuthConfig("key", "secret");
|
||||
assertEquals(OAuthConstants.OUT_OF_BAND, config.getCallback());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void shouldOverrideDefaultsIfSet()
|
||||
{
|
||||
OAuthConfig config = new OAuthConfig();
|
||||
config.setCallback("http://callback");
|
||||
config.setApiKey("key");
|
||||
config.setApiSecret("secret");
|
||||
OAuthConfig config = new OAuthConfig("key", "secret", "http://callback");
|
||||
assertEquals("http://callback", config.getCallback());
|
||||
assertEquals("key", config.getApiKey());
|
||||
assertEquals("secret", config.getApiSecret());
|
||||
|
||||
Reference in new issue
Block a user