-
Notifications
You must be signed in to change notification settings - Fork 24
/
build.sbt
92 lines (87 loc) · 2.56 KB
/
build.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
import com.mesosphere.cosmos.CosmosBuild._
import com.mesosphere.cosmos.Deps
val common = project.in(file("cosmos-common"))
.settings(sharedSettings)
.settings(
name := baseDirectory.value.name,
libraryDependencies ++=
Deps.apacheCommons ++
Deps.bijection ++
Deps.circe ++
Deps.curator ++
Deps.fastparse ++
Deps.finch ++
Deps.findbugs ++
Deps.guava ++
Deps.jsonSchema ++
Deps.mustache ++
Deps.scalaCheck ++
Deps.scalaReflect ++
Deps.scalaTest ++
Deps.scalaUri ++
Deps.twitterUtil
)
val server = project.in(file("cosmos-server"))
.settings(sharedSettings)
.settings(filterSettings)
.settings(BuildPlugin.allOneJarSettings("com.mesosphere.cosmos.Cosmos"))
.settings(
name := baseDirectory.value.name,
libraryDependencies ++=
Deps.bijectionUtil ++
Deps.logback ++
Deps.slf4j ++
Deps.twitterCommons ++
Deps.twitterServer
)
.dependsOn(
common
)
val testCommon = project.in(file("cosmos-test-common"))
.settings(sharedSettings)
.settings(
name := baseDirectory.value.name,
libraryDependencies ++=
Deps.mockito ++
Deps.scalaCheckShapeless
)
.dependsOn(
server
)
/**
* Integration test code. Sources are located in the "main" subdirectory so the JAR can be
* published to Maven repositories with a standard POM.
*/
val integrationTests = project.in(file("cosmos-integration-tests"))
.settings(sharedSettings)
.settings(
name := baseDirectory.value.name,
testOptions in IntegrationTest ++= BuildPlugin.itTestOptions(
javaHomeValue = (javaHome in run).value,
// The one-JAR to use is produced by cosmos-server
oneJarValue = (oneJar in server).value,
// No additional properties needed for these tests
additionalProperties = Nil,
streamsValue = (streams in runMain).value
),
// Uses (compile in Compile) in addition to (compile in IntegrationTest), the default
definedTests in IntegrationTest := {
val frameworkMap = (loadedTestFrameworks in IntegrationTest).value
val compileAnalysis = (compile in Compile).value
val itAnalysis = (compile in IntegrationTest).value
val s = (streams in IntegrationTest).value
Tests.discover(frameworkMap.values.toList, compileAnalysis, s.log)._1 ++
Tests.discover(frameworkMap.values.toList, itAnalysis, s.log)._1
}
)
.dependsOn(
testCommon
)
val cosmos = project.in(file("."))
.settings(sharedSettings)
.aggregate(
common,
integrationTests,
server,
testCommon
)