// Path: src/main/java/com/lumata/lib/lupa/ServiceLocator.java
// public interface ServiceLocator {
// 
// 	Scraper getScraper();
// 
// 	HttpService getHttpService();
// 
// 	ImageService getImageService();
// }
// 
// Path: src/main/java/com/lumata/lib/lupa/content/WebContent.java
// public abstract class WebContent {
// 
// 	public static enum Type {
// 		WEBPAGE,
// 		IMAGE,
// 		VIDEO,
// 		AUDIO,
// 		FEED
// 	}
// 
// 	private final String url;
// 	private final String[] aliasUrls;
// 	private Set<String> keywords;
// 
// 	WebContent(String url, String... aliasUrls) {
// 		this.url = url;
// 		this.aliasUrls = aliasUrls;
// 	}
// 
// 	/**
// 	 * Gets the preferred URL of this content
// 	 * 
// 	 * @return the url
// 	 */
// 	public String getUrl() {
// 		return url;
// 	}
// 
// 	/**
// 	 * Gets the known alias URLs where this content can be also located. The order is defined by the redirection path.
// 	 * 
// 	 * @return the referingUrls
// 	 */
// 	public String[] getAliasUrls() {
// 		return aliasUrls;
// 	}
// 
// 	/**
// 	 * @return the type of this web content.
// 	 */
// 	public abstract Type getType();
// 
// 	/**
// 	 * @return the keywords of this web content.
// 	 */
// 	public Set<String> getKeywords() {
// 		return keywords;
// 	}
// 
// 	/**
// 	 * @param keywords
// 	 *            the keywords to set
// 	 */
// 	public void setKeywords(Set<String> keywords) {
// 		this.keywords = keywords;
// 	}
// 
// 	@Override
// 	public int hashCode() {
// 		return Objects.hashCode(url, getType());
// 	}
// 
// 	@Override
// 	public boolean equals(Object obj) {
// 		if (obj == null || !(obj instanceof WebContent)) {
// 			return false;
// 		}
// 		WebContent that = (WebContent) obj;
// 		return Objects.equal(this.url, that.url) && Objects.equal(this.getType(), that.getType())
// 				&& Arrays.equals(this.aliasUrls, that.aliasUrls) && Objects.equal(this.keywords, that.keywords);
// 	}
// 
// 	protected ToStringHelper toStringHelper(Object instance) {
// 		return Objects.toStringHelper(this).omitNullValues().add("url", url)
// 				.add("aliasUrls", Arrays.toString(aliasUrls)).add("keywords", keywords);
// 	}
// 
// }
// 
// Path: src/main/java/com/lumata/lib/lupa/extractor/ContentExtractorFactory.java
// public interface ContentExtractorFactory {
// 	/**
// 	 * @param resource
// 	 *            the resource to extract the content from.
// 	 * @param scraper
// 	 *            the scraper to use internally by the content scraper.
// 	 * @return
// 	 */
// 	<E extends WebContent> Optional<ContentExtractor<E>> getExtractor(ReadableResource resource, Class<E> webContentType);
// 
// 	/**
// 	 * @param resource
// 	 *            the resource to extract the content from.
// 	 * @param scraper
// 	 *            the scraper to use internally by the content scraper.
// 	 * @return
// 	 */
// 	Optional<ContentExtractor<WebContent>> getExtractor(ReadableResource resource);
// 
// }


import static org.mockito.Mockito.mock;
import java.io.IOException;
import org.junit.Before;
import org.junit.Test;
import com.lumata.lib.lupa.ServiceLocator;
import com.lumata.lib.lupa.content.WebContent;
import com.lumata.lib.lupa.extractor.ContentExtractorFactory;

package com.lumata.lib.lupa.internal;





public class ScraperImplTest {

	private static final String TEST_URL = "http://example.com";

	private ScraperImpl scraper;

// Path: src/main/java/com/lumata/lib/lupa/ServiceLocator.java
// public interface ServiceLocator {
// 
// 	Scraper getScraper();
// 
// 	HttpService getHttpService();
// 
// 	ImageService getImageService();
// }
// 
// Path: src/main/java/com/lumata/lib/lupa/content/WebContent.java
// public abstract class WebContent {
// 
// 	public static enum Type {
// 		WEBPAGE,
// 		IMAGE,
// 		VIDEO,
// 		AUDIO,
// 		FEED
// 	}
// 
// 	private final String url;
// 	private final String[] aliasUrls;
// 	private Set<String> keywords;
// 
// 	WebContent(String url, String... aliasUrls) {
// 		this.url = url;
// 		this.aliasUrls = aliasUrls;
// 	}
// 
// 	/**
// 	 * Gets the preferred URL of this content
// 	 * 
// 	 * @return the url
// 	 */
// 	public String getUrl() {
// 		return url;
// 	}
// 
// 	/**
// 	 * Gets the known alias URLs where this content can be also located. The order is defined by the redirection path.
// 	 * 
// 	 * @return the referingUrls
// 	 */
// 	public String[] getAliasUrls() {
// 		return aliasUrls;
// 	}
// 
// 	/**
// 	 * @return the type of this web content.
// 	 */
// 	public abstract Type getType();
// 
// 	/**
// 	 * @return the keywords of this web content.
// 	 */
// 	public Set<String> getKeywords() {
// 		return keywords;
// 	}
// 
// 	/**
// 	 * @param keywords
// 	 *            the keywords to set
// 	 */
// 	public void setKeywords(Set<String> keywords) {
// 		this.keywords = keywords;
// 	}
// 
// 	@Override
// 	public int hashCode() {
// 		return Objects.hashCode(url, getType());
// 	}
// 
// 	@Override
// 	public boolean equals(Object obj) {
// 		if (obj == null || !(obj instanceof WebContent)) {
// 			return false;
// 		}
// 		WebContent that = (WebContent) obj;
// 		return Objects.equal(this.url, that.url) && Objects.equal(this.getType(), that.getType())
// 				&& Arrays.equals(this.aliasUrls, that.aliasUrls) && Objects.equal(this.keywords, that.keywords);
// 	}
// 
// 	protected ToStringHelper toStringHelper(Object instance) {
// 		return Objects.toStringHelper(this).omitNullValues().add("url", url)
// 				.add("aliasUrls", Arrays.toString(aliasUrls)).add("keywords", keywords);
// 	}
// 
// }
// 
// Path: src/main/java/com/lumata/lib/lupa/extractor/ContentExtractorFactory.java
// public interface ContentExtractorFactory {
// 	/**
// 	 * @param resource
// 	 *            the resource to extract the content from.
// 	 * @param scraper
// 	 *            the scraper to use internally by the content scraper.
// 	 * @return
// 	 */
// 	<E extends WebContent> Optional<ContentExtractor<E>> getExtractor(ReadableResource resource, Class<E> webContentType);
// 
// 	/**
// 	 * @param resource
// 	 *            the resource to extract the content from.
// 	 * @param scraper
// 	 *            the scraper to use internally by the content scraper.
// 	 * @return
// 	 */
// 	Optional<ContentExtractor<WebContent>> getExtractor(ReadableResource resource);
// 
// }


// Path: src/test/java/com/lumata/lib/lupa/internal/ScraperImplTest.java
import static org.mockito.Mockito.mock;
import java.io.IOException;
import org.junit.Before;
import org.junit.Test;
import com.lumata.lib.lupa.ServiceLocator;
import com.lumata.lib.lupa.content.WebContent;
import com.lumata.lib.lupa.extractor.ContentExtractorFactory;

package com.lumata.lib.lupa.internal;





public class ScraperImplTest {

	private static final String TEST_URL = "http://example.com";

	private ScraperImpl scraper;

	private ContentExtractorFactory extractorFactoryMock;
