projects
/
Sone.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Allow adding posts without specific ID
[Sone.git]
/
src
/
test
/
kotlin
/
net
/
pterodactylus
/
sone
/
web
/
ajax
/
JsonPageTest.kt
diff --git
a/src/test/kotlin/net/pterodactylus/sone/web/ajax/JsonPageTest.kt
b/src/test/kotlin/net/pterodactylus/sone/web/ajax/JsonPageTest.kt
index
58f7823
..
5656874
100644
(file)
--- a/
src/test/kotlin/net/pterodactylus/sone/web/ajax/JsonPageTest.kt
+++ b/
src/test/kotlin/net/pterodactylus/sone/web/ajax/JsonPageTest.kt
@@
-178,8
+178,8
@@
abstract class JsonPageTest(
localSones += id to sone
}
localSones += id to sone
}
- protected fun addPost(
id: String, post: Post
) {
- posts[id] = post
+ protected fun addPost(
post: Post, id: String? = null
) {
+ posts[id
?: post.id
] = post
}
protected fun addNewPost(id: String, soneId: String, time: Long, recipientId: String? = null) =
}
protected fun addNewPost(id: String, soneId: String, time: Long, recipientId: String? = null) =