@@ -36,7 +36,7 @@ public void shouldAddHeader() throws Exception {
3636 .sign (Algorithm .HMAC256 ("secret" ));
3737
3838 assertThat (signed , is (notNullValue ()));
39- assertThat (SignUtils .splitToken (signed )[0 ], is ("eyJhbGciOiJIUzI1NiIsImFzZCI6MTIzfQ" ));
39+ assertThat (TokenUtils .splitToken (signed )[0 ], is ("eyJhbGciOiJIUzI1NiIsImFzZCI6MTIzfQ" ));
4040 }
4141
4242 @ Test
@@ -46,7 +46,7 @@ public void shouldAddIssuer() throws Exception {
4646 .sign (Algorithm .HMAC256 ("secret" ));
4747
4848 assertThat (signed , is (notNullValue ()));
49- assertThat (SignUtils .splitToken (signed )[1 ], is ("eyJpc3MiOiJhdXRoMCJ9" ));
49+ assertThat (TokenUtils .splitToken (signed )[1 ], is ("eyJpc3MiOiJhdXRoMCJ9" ));
5050 }
5151
5252 @ Test
@@ -56,7 +56,7 @@ public void shouldAddSubject() throws Exception {
5656 .sign (Algorithm .HMAC256 ("secret" ));
5757
5858 assertThat (signed , is (notNullValue ()));
59- assertThat (SignUtils .splitToken (signed )[1 ], is ("eyJzdWIiOiIxMjM0NTY3ODkwIn0" ));
59+ assertThat (TokenUtils .splitToken (signed )[1 ], is ("eyJzdWIiOiIxMjM0NTY3ODkwIn0" ));
6060 }
6161
6262 @ Test
@@ -66,15 +66,15 @@ public void shouldAddAudience() throws Exception {
6666 .sign (Algorithm .HMAC256 ("secret" ));
6767
6868 assertThat (signed , is (notNullValue ()));
69- assertThat (SignUtils .splitToken (signed )[1 ], is ("eyJhdWQiOiJNYXJrIn0" ));
69+ assertThat (TokenUtils .splitToken (signed )[1 ], is ("eyJhdWQiOiJNYXJrIn0" ));
7070
7171
7272 String signedArr = JWTCreator .init ()
7373 .withAudience (new String []{"Mark" , "David" })
7474 .sign (Algorithm .HMAC256 ("secret" ));
7575
7676 assertThat (signedArr , is (notNullValue ()));
77- assertThat (SignUtils .splitToken (signedArr )[1 ], is ("eyJhdWQiOlsiTWFyayIsIkRhdmlkIl19" ));
77+ assertThat (TokenUtils .splitToken (signedArr )[1 ], is ("eyJhdWQiOlsiTWFyayIsIkRhdmlkIl19" ));
7878 }
7979
8080 @ Test
@@ -84,7 +84,7 @@ public void shouldAddExpiresAt() throws Exception {
8484 .sign (Algorithm .HMAC256 ("secret" ));
8585
8686 assertThat (signed , is (notNullValue ()));
87- assertThat (SignUtils .splitToken (signed )[1 ], is ("eyJleHAiOjE0Nzc1OTJ9" ));
87+ assertThat (TokenUtils .splitToken (signed )[1 ], is ("eyJleHAiOjE0Nzc1OTJ9" ));
8888 }
8989
9090 @ Test
@@ -94,7 +94,7 @@ public void shouldAddNotBefore() throws Exception {
9494 .sign (Algorithm .HMAC256 ("secret" ));
9595
9696 assertThat (signed , is (notNullValue ()));
97- assertThat (SignUtils .splitToken (signed )[1 ], is ("eyJuYmYiOjE0Nzc1OTJ9" ));
97+ assertThat (TokenUtils .splitToken (signed )[1 ], is ("eyJuYmYiOjE0Nzc1OTJ9" ));
9898 }
9999
100100 @ Test
@@ -104,7 +104,7 @@ public void shouldAddIssuedAt() throws Exception {
104104 .sign (Algorithm .HMAC256 ("secret" ));
105105
106106 assertThat (signed , is (notNullValue ()));
107- assertThat (SignUtils .splitToken (signed )[1 ], is ("eyJpYXQiOjE0Nzc1OTJ9" ));
107+ assertThat (TokenUtils .splitToken (signed )[1 ], is ("eyJpYXQiOjE0Nzc1OTJ9" ));
108108 }
109109
110110 @ Test
@@ -114,7 +114,7 @@ public void shouldAddJWTId() throws Exception {
114114 .sign (Algorithm .HMAC256 ("secret" ));
115115
116116 assertThat (signed , is (notNullValue ()));
117- assertThat (SignUtils .splitToken (signed )[1 ], is ("eyJqdGkiOiJqd3RfaWRfMTIzIn0" ));
117+ assertThat (TokenUtils .splitToken (signed )[1 ], is ("eyJqdGkiOiJqd3RfaWRfMTIzIn0" ));
118118 }
119119
120120
@@ -126,7 +126,7 @@ public void shouldRemoveClaimWhenPassingNull() throws Exception {
126126 .sign (Algorithm .HMAC256 ("secret" ));
127127
128128 assertThat (signed , is (notNullValue ()));
129- assertThat (SignUtils .splitToken (signed )[1 ], is ("e30" ));
129+ assertThat (TokenUtils .splitToken (signed )[1 ], is ("e30" ));
130130 }
131131
132132 @ Test
@@ -135,15 +135,15 @@ public void shouldSetCorrectAlgorithmInTheHeader() throws Exception {
135135 .sign (Algorithm .HMAC256 ("secret" ));
136136
137137 assertThat (signed , is (notNullValue ()));
138- assertThat (SignUtils .splitToken (signed )[0 ], is ("eyJhbGciOiJIUzI1NiJ9" ));
138+ assertThat (TokenUtils .splitToken (signed )[0 ], is ("eyJhbGciOiJIUzI1NiJ9" ));
139139 }
140140
141141 @ Test
142142 public void shouldSetEmptySignatureIfAlgorithmIsNone () throws Exception {
143143 String signed = JWTCreator .init ()
144144 .sign (Algorithm .none ());
145145 assertThat (signed , is (notNullValue ()));
146- assertThat (SignUtils .splitToken (signed )[2 ], is ("" ));
146+ assertThat (TokenUtils .splitToken (signed )[2 ], is ("" ));
147147 }
148148
149149}
0 commit comments