#30 Add tests for jwt logic and group token logic
This commit is contained in:
parent
ed0e5d89d3
commit
d02faf7bce
|
@ -106,10 +106,6 @@ tasks.withType<JavaCompile>() {
|
|||
tasks.withType<KotlinCompile>().all {
|
||||
kotlinOptions {
|
||||
jvmTarget = JavaVersion.VERSION_17.toString()
|
||||
freeCompilerArgs = listOf(
|
||||
"-Xopt-in=kotlin.contracts.ExperimentalContracts",
|
||||
"-Xinline-classes"
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -21,6 +21,7 @@ object Constants {
|
|||
|
||||
const val LOGIN = "$BASE_PATH/account/login"
|
||||
const val GROUP_LOGIN = "$BASE_PATH/account/login/group"
|
||||
const val LOGOUT = "$BASE_PATH/account/logout"
|
||||
}
|
||||
|
||||
object CookieNames {
|
||||
|
|
|
@ -78,10 +78,10 @@ class UserController(private val userLogic: UserLogic) {
|
|||
}
|
||||
|
||||
@RestController
|
||||
@RequestMapping("api")
|
||||
@RequestMapping(Constants.ControllerPaths.LOGOUT)
|
||||
@Profile("!emergency")
|
||||
class LogoutController(private val userLogic: UserLogic) {
|
||||
@GetMapping("logout")
|
||||
@GetMapping
|
||||
@PreAuthorize("isFullyAuthenticated()")
|
||||
fun logout(request: HttpServletRequest) =
|
||||
ok {
|
||||
|
|
Loading…
Reference in New Issue