mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-05-11 13:17:29 +08:00
Merge pull request #158 from nagisa77/codex/fix-usercontrollertest-null-pointer-exception
Fix user replies test to set post category
This commit is contained in:
@@ -114,6 +114,9 @@ class UserControllerTest {
|
|||||||
user.setUsername("bob");
|
user.setUsername("bob");
|
||||||
com.openisle.model.Post post = new com.openisle.model.Post();
|
com.openisle.model.Post post = new com.openisle.model.Post();
|
||||||
post.setId(5L);
|
post.setId(5L);
|
||||||
|
com.openisle.model.Category cat = new com.openisle.model.Category();
|
||||||
|
cat.setName("tech");
|
||||||
|
post.setCategory(cat);
|
||||||
com.openisle.model.Comment comment = new com.openisle.model.Comment();
|
com.openisle.model.Comment comment = new com.openisle.model.Comment();
|
||||||
comment.setId(4L);
|
comment.setId(4L);
|
||||||
comment.setContent("hi");
|
comment.setContent("hi");
|
||||||
|
|||||||
Reference in New Issue
Block a user