Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
佳 邓
Gitlab4j Api
Commits
7107e9db
Commit
7107e9db
authored
May 04, 2019
by
Greg Messner
Browse files
Added testing of Application and Email models (#338, #339).
parent
3697df3d
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/test/java/org/gitlab4j/api/TestGitLabApiBeans.java
View file @
7107e9db
...
...
@@ -32,6 +32,7 @@ import static org.junit.Assert.assertTrue;
import
java.util.List
;
import
java.util.Map
;
import
org.gitlab4j.api.models.Application
;
import
org.gitlab4j.api.models.ArtifactsFile
;
import
org.gitlab4j.api.models.AwardEmoji
;
import
org.gitlab4j.api.models.Board
;
...
...
@@ -44,6 +45,7 @@ import org.gitlab4j.api.models.CompareResults;
import
org.gitlab4j.api.models.DeployKey
;
import
org.gitlab4j.api.models.Diff
;
import
org.gitlab4j.api.models.Discussion
;
import
org.gitlab4j.api.models.Email
;
import
org.gitlab4j.api.models.Epic
;
import
org.gitlab4j.api.models.EpicIssue
;
import
org.gitlab4j.api.models.Event
;
...
...
@@ -86,6 +88,12 @@ import org.junit.Test;
public
class
TestGitLabApiBeans
{
@Test
public
void
testApplications
()
throws
Exception
{
List
<
Application
>
applications
=
unmarshalResourceList
(
Application
.
class
,
"applications.json"
);
assertTrue
(
compareJson
(
applications
,
"applications.json"
));
}
@Test
public
void
testAwardEmoji
()
throws
Exception
{
AwardEmoji
awardEmoji
=
unmarshalResource
(
AwardEmoji
.
class
,
"award-emoji.json"
);
...
...
@@ -144,6 +152,12 @@ public class TestGitLabApiBeans {
assertTrue
(
compareJson
(
comment
,
"comment.json"
));
}
@Test
public
void
testEmails
()
throws
Exception
{
List
<
Email
>
emails
=
unmarshalResourceList
(
Email
.
class
,
"emails.json"
);
assertTrue
(
compareJson
(
emails
,
"emails.json"
));
}
@Test
public
void
testEpic
()
throws
Exception
{
Epic
epic
=
unmarshalResource
(
Epic
.
class
,
"epic.json"
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment