1
0
mirror of https://github.com/pcvolkmer/onco-analytics-monitor.git synced 2025-07-03 09:12:54 +00:00

test: add tests for InMemoryConditionRepository

This commit is contained in:
2024-08-07 21:05:21 +02:00
parent b07675fabb
commit afa9be27b9
2 changed files with 48 additions and 2 deletions

View File

@ -42,8 +42,7 @@ class InMemoryConditionRepository : ConditionRepository {
override fun saveIfNewerVersion(condition: Condition): Boolean {
if ((this.conditions[condition.id]?.version ?: 0) < condition.version) {
this.conditions[condition.id] = condition
return true
return this.save(condition)
}
return false
}