    @Test
    public void testFindArtifactInRepository() throws MojoExecutionException {

        GenerateMojo mojo = new GenerateMojo();
        mojo.setLog(new SystemStreamLog());

        Dependency dependency = mojo.findArtifactInRepository(
                new DefaultArtifact("org.spigotmc", "spigot-api", "1.8-R0.1-SNAPSHOT",
                                    "compile", "jar", "jar", new DefaultArtifactHandler()),
                new MavenArtifactRepository("yawkat",
                                            "http://mvn.yawk.at",
                                            new DefaultRepositoryLayout(),
                                            new ArtifactRepositoryPolicy(),
                                            new ArtifactRepositoryPolicy())
        );
        Assert.assertNotNull(dependency);
    }