46 JsonObject tokenObj =
new JsonObject();
47 tokenObj.addProperty(
"active",
true);
49 tokenObj.addProperty(
"exp",
expVal);
50 tokenObj.addProperty(
"sub",
"subject");
51 tokenObj.addProperty(
"client_id",
"123-456-789");
53 OAuth2AccessTokenImpl tok =
new OAuth2AccessTokenImpl(tokenObj,
tokenString);
55 assertThat(tok.getScope(), is(equalTo(
scopes)));
56 assertThat(tok.getExpiration(), is(equalTo(
exp)));
static String scopeString
Definition: TestOAuth2AccessTokenImpl.java:37
static Long expVal
Definition: TestOAuth2AccessTokenImpl.java:40
static Set< String > scopes
Definition: TestOAuth2AccessTokenImpl.java:36
static Date exp
Definition: TestOAuth2AccessTokenImpl.java:39
static String tokenString
Definition: TestOAuth2AccessTokenImpl.java:34