Skip to content

Commit 4a7802f

Browse files
committed
Made tests module compile for scala, disabled scala in core module
1 parent bf5e3e9 commit 4a7802f

File tree

2 files changed

+26
-23
lines changed

2 files changed

+26
-23
lines changed

core/build.gradle

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,9 @@
11

22
apply plugin: 'java'
33
apply plugin: 'maven'
4-
apply plugin: 'scala'
54

65
defaultTasks 'build'
76

8-
ext {
9-
scalaVersion = "2.10.+"
10-
scalacheckVersion = "1.10.+"
11-
scalacheckScalaVersion = "2.10"
12-
}
13-
14-
tasks.withType(ScalaCompile) {
15-
scalaCompileOptions.useAnt = false
16-
}
17-
18-
test {
19-
scanForTestClasses = false
20-
include '**/*Test.*'
21-
}
227

238
jar {
249
baseName project.projectName
@@ -34,8 +19,6 @@ repositories {
3419

3520
dependencies {
3621
compile 'org.slf4j:slf4j-api:1.7.5'
37-
testCompile "org.scala-lang:scala-library:$scalaVersion"
38-
testCompile "org.scalacheck:scalacheck_$scalacheckScalaVersion:$scalacheckVersion"
3922

4023
testCompile "junit:junit:4.11"
4124
}

tests/build.gradle

Lines changed: 26 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,39 @@
1010
// Apply the scala plugin to add support for Scala
1111
apply plugin: 'scala'
1212

13+
14+
ext {
15+
scalaVersion = "2.10.+"
16+
scalacheckVersion = "1.10.+"
17+
scalacheckScalaVersion = "2.10"
18+
}
19+
20+
21+
22+
tasks.withType(ScalaCompile) {
23+
scalaCompileOptions.useAnt = false
24+
}
25+
26+
27+
test {
28+
scanForTestClasses = false
29+
include '**/*Test.*'
30+
}
31+
1332
// In this section you declare where to find the dependencies of your project
1433
repositories {
1534
// Use 'maven central' for resolving your dependencies.
1635
// You can declare any Maven/Ivy/file repository here.
1736
mavenCentral()
1837
}
1938

20-
// In this section you declare the dependencies for your production and test code
39+
2140
dependencies {
22-
// We use the latest 2.10 scala version in our library project
23-
compile 'org.scala-lang:scala-library:2.10.3'
41+
compile 'org.slf4j:slf4j-api:1.7.5'
42+
compile "org.scala-lang:scala-library:$scalaVersion"
43+
testCompile "org.scala-lang:scala-library:$scalaVersion"
44+
testCompile "org.scalacheck:scalacheck_$scalacheckScalaVersion:$scalacheckVersion"
2445

25-
// We use the latest version of the scalatest for testing our library
26-
testCompile 'junit:junit:4.11'
27-
testCompile 'org.scalatest:scalatest_2.10:1.9.2'
46+
testCompile "junit:junit:4.11"
47+
testCompile 'org.scalatest:scalatest_2.10:1.9.2'
2848
}

0 commit comments

Comments
 (0)