Rename class that fetches a Sone with its URI.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Thu, 31 Jul 2014 19:14:37 +0000 (21:14 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Thu, 31 Jul 2014 19:18:10 +0000 (21:18 +0200)
src/main/java/net/pterodactylus/sone/core/Core.java
src/main/java/net/pterodactylus/sone/core/SoneDownloader.java
src/test/java/net/pterodactylus/sone/core/SoneDownloaderTest.java

index ffed7a9..b9fb766 100644 (file)
@@ -800,7 +800,7 @@ public class Core extends AbstractService implements SoneProvider, PostProvider,
                                }
                        }
                        soneDownloader.addSone(sone);
-                       soneDownloaders.execute(soneDownloader.new FetchSone(sone));
+                       soneDownloaders.execute(soneDownloader.new FetchSoneWithUri(sone));
                        return sone;
                }
        }
index 8b3ad79..8f4bf7d 100644 (file)
@@ -533,11 +533,11 @@ public class SoneDownloader extends AbstractService {
                }
        }
 
-       public class FetchSone implements Runnable {
+       public class FetchSoneWithUri implements Runnable {
 
                private final Sone sone;
 
-               public FetchSone(Sone sone) {
+               public FetchSoneWithUri(Sone sone) {
                        this.sone = sone;
                }
 
index 413b8ff..73920ff 100644 (file)
@@ -5,7 +5,7 @@ import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.verify;
 import static org.mockito.Mockito.when;
 
-import net.pterodactylus.sone.core.SoneDownloader.FetchSone;
+import net.pterodactylus.sone.core.SoneDownloader.FetchSoneWithUri;
 import net.pterodactylus.sone.data.Sone;
 
 import freenet.keys.FreenetURI;
@@ -20,13 +20,13 @@ import org.junit.Test;
 public class SoneDownloaderTest {
 
        @Test
-       public void fetchSoneDownloadsSone() {
+       public void fetchSoneWithUriDownloadsSoneWithUri() {
                SoneDownloader soneDownloader = mock(SoneDownloader.class);
                Sone sone = mock(Sone.class);
                FreenetURI soneUri = mock(FreenetURI.class);
                when(sone.getRequestUri()).thenReturn(soneUri);
-               FetchSone fetchSone = soneDownloader.new FetchSone(sone);
-               fetchSone.run();
+               FetchSoneWithUri fetchSoneWithUri = soneDownloader.new FetchSoneWithUri(sone);
+               fetchSoneWithUri.run();
                verify(soneDownloader).fetchSone(eq(sone), eq(soneUri));
        }