mirror of
https://github.com/usatiuk/y.git
synced 2025-10-28 10:37:47 +01:00
fix tests
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
flex-wrap: wrap;
|
||||
|
||||
.profileCard {
|
||||
flex-grow: 0;
|
||||
margin: 0.2rem;
|
||||
}
|
||||
}
|
||||
@@ -23,7 +23,7 @@ public class TokenServiceImpl implements TokenService {
|
||||
|
||||
public TokenServiceImpl(@Value("${jwt.secret}") String secret) {
|
||||
// FIXME:
|
||||
this.key = Keys.hmacShaKeyFor(Decoders.BASE64.decode(Encoders.BASE64.encode(secret.getBytes())));
|
||||
this.key = Keys.hmacShaKeyFor(secret.getBytes());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -75,7 +75,7 @@ public class PostControllerTest extends DemoDataDbTest {
|
||||
|
||||
@Test
|
||||
void shouldGetPostsByFollowees() {
|
||||
var response = restTemplate.exchange(addr + "/post/following",
|
||||
var response = restTemplate.exchange(addr + "/post/by-following",
|
||||
HttpMethod.GET, new HttpEntity<>(createAuthHeaders(person3Auth)), PostTo[].class);
|
||||
|
||||
Assertions.assertEquals(HttpStatus.OK, response.getStatusCode());
|
||||
|
||||
Reference in New Issue
Block a user