-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7 from maiflai/master
fix links to source files
- Loading branch information
Showing
7 changed files
with
76 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package org.scoverage | ||
|
||
import org.gradle.tooling.GradleConnector | ||
import org.junit.Test | ||
|
||
import static org.junit.Assert.assertThat | ||
import static org.hamcrest.core.Is.is | ||
|
||
class PluginAcceptanceTest { | ||
|
||
@Test | ||
public void testProjectWithCompleteCoverage() throws Exception { | ||
def build = GradleConnector. | ||
newConnector(). | ||
forProjectDirectory(new File("src/test/happyday")). | ||
connect().newBuild() | ||
build.forTasks('clean', 'checkScoverage').run() | ||
|
||
def html = new File('src/test/happyday/build/reports/scoverage/index.html') | ||
assertThat('an HTML file should be created at ' + html.absolutePath, html.exists(), is(true)) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
description = 'a project that builds successfully with 100% coverage' | ||
|
||
buildscript { | ||
repositories { | ||
// need to get up to the working directory of gradle-plugins build | ||
flatDir dir: "${project.projectDir}/../../../build/libs" | ||
} | ||
dependencies { | ||
classpath name: 'gradle-scoverage', version: '+' | ||
} | ||
} | ||
|
||
apply plugin: 'scoverage' | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
dependencies { | ||
scoverage 'org.scoverage:scalac-scoverage-plugin_2.11:0.99.5' | ||
compile 'org.scala-lang:scala-library:2.11.0' | ||
testCompile 'junit:junit:4.11' | ||
} | ||
|
||
checkScoverage { | ||
minimumLineRate = 1.0 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package hello | ||
|
||
object World { | ||
def say() = println("ahoy") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package hello | ||
|
||
import org.junit.Test | ||
|
||
class WorldTest { | ||
@Test | ||
def bob() { | ||
World.say() | ||
} | ||
} |