Skip to content

Commit

Permalink
Merge branch 'master' into dependabot/gradle/org.junit.jupiter-junit-…
Browse files Browse the repository at this point in the history
…jupiter-5.9.3
  • Loading branch information
w3stling authored Jun 1, 2023
2 parents 7d2f070 + a4715fd commit fcd04b6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 41 deletions.
8 changes: 4 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ plugins {
id 'signing'
id 'maven-publish'
id 'io.github.gradle-nexus.publish-plugin' version '1.3.0'
id 'org.sonarqube' version '4.0.0.2929'
id 'org.sonarqube' version '4.2.0.3129'
}

group 'com.apptasticsoftware'
Expand All @@ -18,12 +18,12 @@ repositories {
}

dependencies {
testImplementation(platform('org.junit:junit-bom:5.9.2'))
testImplementation(platform('org.junit:junit-bom:5.9.3'))
testImplementation('org.junit.jupiter:junit-jupiter:5.9.3')
testImplementation('com.github.npathai:hamcrest-optional:2.0.0')
testImplementation('org.hamcrest:hamcrest:2.2')
testImplementation('org.mockito:mockito-core:5.2.0')
testImplementation('nl.jqno.equalsverifier:equalsverifier:3.14.1')
testImplementation('org.mockito:mockito-core:5.3.1')
testImplementation('nl.jqno.equalsverifier:equalsverifier:3.14.2')
}

test {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -271,42 +271,6 @@ void rssVAFinansBadUrl() {
}


@Test
void feedForAll() throws IOException {
RssReader reader = new RssReader();
List<Item> items = reader.read("https://feedforall.com/sample-feed.xml").collect(Collectors.toList());

assertFalse(items.isEmpty());

for (Item item : items) {
// Validate channel
Channel channel = item.getChannel();
assertNotNull(channel);
assertThat(channel.getTitle(), is("Sample Feed - Favorite RSS Related Software & Resources"));
assertThat(channel.getDescription(), is("Take a look at some of FeedForAll's favorite software and resources for learning more about RSS."));
assertThat(channel.getLink(), is("http://www.feedforall.com"));
assertThat(channel.getCategories().get(0), is("Computers/Software/Internet/Site Management/Content Management"));
assertThat(channel.getLanguage(), isPresentAndIs("en-us"));
assertThat(channel.getCopyright(), isPresentAndIs("Copyright 2004 NotePage, Inc."));
assertThat(channel.getGenerator(), isPresentAndIs("FeedForAll Beta1 (0.0.1.8)"));
assertThat(channel.getPubDate(), isPresentAndIs("Tue, 26 Oct 2004 14:06:44 -0500"));
assertThat(channel.getPubDateZonedDateTime(), isPresentAndIs(DateTime.toZonedDateTime("Tue, 26 Oct 2004 14:06:44 -0500")));
assertThat(channel.getLastBuildDate(), isPresentAndIs("Mon, 1 Nov 2004 13:17:17 -0500"));
assertThat(channel.getLastBuildDateZonedDateTime(), isPresentAndIs(DateTime.toZonedDateTime("Mon, 1 Nov 2004 13:17:17 -0500")));

// Validate item
assertNotNull(item);
assertThat(item.getGuid(), isEmpty());
assertThat(item.getIsPermaLink(), isEmpty());
assertThat(item.getTitle(), isPresent());
assertThat(item.getDescription(), isPresent());
assertThat(item.getPubDate(), isPresent());
assertThat(item.getPubDateZonedDateTime(), isPresent());
assertThat(item.getLink(), isPresent());
}
}


@Test
void investingcom() throws IOException {
RssReader reader = new RssReader();
Expand Down Expand Up @@ -415,7 +379,7 @@ void rssWorldOfTank() throws IOException {
Channel channel = item.getChannel();
assertNotNull(channel);
assertThat(channel.getTitle(), containsString("World of Tanks"));
assertThat(channel.getDescription(), is("The latest news, updates, specials, and events for World of Tanks, the team-based, MMO tank battle game from Wargaming. Everything about WoT in one place."));
assertThat(channel.getDescription(), anything());
assertThat(channel.getLanguage(), isPresentAndIs("en"));
assertThat(channel.getLink(), is("https://worldoftanks.eu/en/news/"));
assertThat(channel.getImage(), isPresent());
Expand Down

0 comments on commit fcd04b6

Please sign in to comment.