diff options
author | Vitaly Takmazov | 2016-01-15 14:49:51 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2016-01-15 14:49:51 +0300 |
commit | f9d5099bf4be816aa267e02b5713a672fd4da562 (patch) | |
tree | a3cd6f2015fb823ad4a25035f8dfe36c1deede23 /src/test/java | |
parent | 552bc5210ecc06e58dcf4d67fb6191dbac2a219c (diff) |
spring-jdbc WIP
Diffstat (limited to 'src/test/java')
-rw-r--r-- | src/test/java/com/juick/tests/ApiTests.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/test/java/com/juick/tests/ApiTests.java b/src/test/java/com/juick/tests/ApiTests.java index f111ffc7..e67c23f2 100644 --- a/src/test/java/com/juick/tests/ApiTests.java +++ b/src/test/java/com/juick/tests/ApiTests.java @@ -1,7 +1,9 @@ package com.juick.tests; +import com.juick.Message; import com.juick.User; import com.juick.server.UserQueries; +import com.juick.server.MessagesQueries; import junit.framework.Assert; import org.apache.commons.dbcp2.BasicDataSource; import org.junit.Before; @@ -38,4 +40,11 @@ public class ApiTests { User user = UserQueries.getUserByUID(jdbc, 3694); Assert.assertEquals("it should be me", "vt", user.UName); } + + @Test void messageTests() { + Message msg = MessagesQueries.getMessage(jdbc, 2817722); + User ugnich = msg.User; + Assert.assertEquals("ugnich", ugnich.UName); + Assert.assertEquals("Microsoft", msg.Tags.get(0)); + } } |