Skip to content

Commit 25887bf

Browse files
committed
Small fix for name
1 parent e8f953b commit 25887bf

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/main/java/cd/go/authorization/okta/models/User.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ public class User {
2626
private String username;
2727

2828
@Expose
29-
@SerializedName("name")
29+
@SerializedName("display_name")
3030
private String displayName;
3131

3232
@Expose

src/test/java/cd/go/authorization/okta/executors/UserAuthenticationRequestExecutorTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public void shouldAuthenticate() throws Exception {
8686
" \"roles\": [],\n" +
8787
" \"user\": {\n" +
8888
" \"username\": \"foo@bar.com\",\n" +
89-
" \"name\": \"Foo Bar\",\n" +
89+
" \"display_name\": \"Foo Bar\",\n" +
9090
" \"email\": \"foo@bar.com\"\n" +
9191
" }\n" +
9292
"}";

src/test/java/cd/go/authorization/okta/models/UserTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public class UserTest {
2929
@Test
3030
public void shouldSerializeToJSON() throws Exception {
3131
final User user = new User("foo", "bar", "baz");
32-
final String expectedJSON = "{\"username\":\"foo\",\"name\":\"bar\",\"email\":\"baz\"}";
32+
final String expectedJSON = "{\"username\":\"foo\",\"display_name\":\"bar\",\"email\":\"baz\"}";
3333

3434
JSONAssert.assertEquals(expectedJSON, GSON.toJson(user), true);
3535
}

0 commit comments

Comments
 (0)