mirror of
https://github.com/pcvolkmer/mv64e-etl-processor
synced 2025-09-13 17:02:52 +00:00
test: add tests for token requests
This commit is contained in:
@@ -127,10 +127,11 @@ class ConfigController(
|
||||
} else {
|
||||
model.addAttribute("tokensEnabled", true)
|
||||
val result = tokenService.addToken(name)
|
||||
if (result.isSuccess) {
|
||||
model.addAttribute("newTokenValue", result.getOrDefault(""))
|
||||
result.onSuccess {
|
||||
model.addAttribute("newTokenValue", it)
|
||||
model.addAttribute("success", true)
|
||||
} else {
|
||||
}
|
||||
result.onFailure {
|
||||
model.addAttribute("success", false)
|
||||
}
|
||||
model.addAttribute("tokens", tokenService.findAll())
|
||||
|
Reference in New Issue
Block a user