PullRequestInfo { public String getTitle() { return title; } PullRequestInfo(String title, String image, String tag); String getTitle(); String getBody(); static final String BODY_TEMPLATE; static final String DEFAULT_TITLE; static final String OLD_CONSTANT_BODY; }
@Test public void testGetTitle() { PullRequestInfo pullRequestInfo = new PullRequestInfo(TITLE, IMAGE, TAG); assertEquals(pullRequestInfo.getTitle(), TITLE); }
@Test public void testGetDefaultTitleIfNull() { PullRequestInfo pullRequestInfo = new PullRequestInfo(null, IMAGE, TAG); assertEquals(pullRequestInfo.getTitle(), DEFAULT_TITLE); }
@Test public void testGetDefaultTitleIfEmpty() { PullRequestInfo pullRequestInfo = new PullRequestInfo(" ", IMAGE, TAG); assertEquals(pullRequestInfo.getTitle(), DEFAULT_TITLE); }