From b5b9f8645ccbb24d0db376499211bbc5af4d0452 Mon Sep 17 00:00:00 2001 From: Coffeemakr Date: Sat, 25 Nov 2017 02:07:12 +0100 Subject: [PATCH] Convert assertTrue(!..) to assertFalse --- .../services/soundcloud/SoundcloudChannelExtractorTest.java | 2 +- .../soundcloud/SoundcloudStreamExtractorDefaultTest.java | 6 +++--- .../services/youtube/YoutubeStreamExtractorDefaultTest.java | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/test/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudChannelExtractorTest.java b/src/test/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudChannelExtractorTest.java index f7eb2cc7..a2632c22 100644 --- a/src/test/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudChannelExtractorTest.java +++ b/src/test/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudChannelExtractorTest.java @@ -47,7 +47,7 @@ public class SoundcloudChannelExtractorTest { @Test public void testGetStreams() throws Exception { - assertTrue("no streams are received", !extractor.getStreams().getItemList().isEmpty()); + assertFalse("no streams are received", extractor.getStreams().getItemList().isEmpty()); } @Test diff --git a/src/test/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudStreamExtractorDefaultTest.java b/src/test/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudStreamExtractorDefaultTest.java index fe23298b..52af87eb 100644 --- a/src/test/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudStreamExtractorDefaultTest.java +++ b/src/test/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudStreamExtractorDefaultTest.java @@ -23,12 +23,12 @@ import static org.schabi.newpipe.extractor.ServiceList.SoundCloud; * Test for {@link StreamExtractor} */ public class SoundcloudStreamExtractorDefaultTest { - private StreamExtractor extractor; + private SoundcloudStreamExtractor extractor; @Before public void setUp() throws Exception { NewPipe.init(Downloader.getInstance()); - extractor = SoundCloud.getService().getStreamExtractor("https://soundcloud.com/liluzivert/do-what-i-want-produced-by-maaly-raw-don-cannon"); + extractor = (SoundcloudStreamExtractor) SoundCloud.getService().getStreamExtractor("https://soundcloud.com/liluzivert/do-what-i-want-produced-by-maaly-raw-don-cannon"); } @Test @@ -91,7 +91,7 @@ public class SoundcloudStreamExtractorDefaultTest { @Test public void testGetAudioStreams() throws IOException, ExtractionException { - assertTrue(!extractor.getAudioStreams().isEmpty()); + assertFalse(extractor.getAudioStreams().isEmpty()); } @Test diff --git a/src/test/java/org/schabi/newpipe/extractor/services/youtube/YoutubeStreamExtractorDefaultTest.java b/src/test/java/org/schabi/newpipe/extractor/services/youtube/YoutubeStreamExtractorDefaultTest.java index c5d66f4b..df10c76a 100644 --- a/src/test/java/org/schabi/newpipe/extractor/services/youtube/YoutubeStreamExtractorDefaultTest.java +++ b/src/test/java/org/schabi/newpipe/extractor/services/youtube/YoutubeStreamExtractorDefaultTest.java @@ -62,7 +62,7 @@ public class YoutubeStreamExtractorDefaultTest { @Test public void testGetTitle() throws ParsingException { - assertTrue(!extractor.getName().isEmpty()); + assertFalse(extractor.getName().isEmpty()); } @Test @@ -113,7 +113,7 @@ public class YoutubeStreamExtractorDefaultTest { @Test public void testGetAudioStreams() throws IOException, ExtractionException { - assertTrue(!extractor.getAudioStreams().isEmpty()); + assertFalse(extractor.getAudioStreams().isEmpty()); } @Test