-
Notifications
You must be signed in to change notification settings - Fork 33
/
build.sbt
executable file
·66 lines (58 loc) · 1.96 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
name := course.value + "-" + assignment.value
scalaVersion := "2.11.8"
scalacOptions ++= Seq("-deprecation")
courseId := "e8VseYIYEeWxQQoymFg8zQ"
resolvers += Resolver.sonatypeRepo("releases")
// grading libraries
libraryDependencies += "junit" % "junit" % "4.10" % "test"
libraryDependencies ++= assignmentsMap.value.values.flatMap(_.dependencies).toSeq
// include the common dir
commonSourcePackages += "common"
assignmentsMap := {
val depsSpark = Seq(
"org.apache.spark" %% "spark-core" % "2.1.0"
)
Map(
"example" -> Assignment(
packageName = "example",
key = "9W3VuiJREeaFaw43_UrNUw",
itemId = "I6L8m",
partId = "vsJoj",
maxScore = 10d,
dependencies = depsSpark,
options = Map("Xmx"->"1540m", "grader-memory"->"2048")),
"wikipedia" -> Assignment(
packageName = "wikipedia",
key = "EH8wby4kEeawURILfHIqjw",
itemId = "QcWcs",
partId = "5komc",
maxScore = 10d,
styleScoreRatio = 0.0,
dependencies = depsSpark,
options = Map("Xmx"->"1540m", "grader-memory"->"2048", "totalTimeout" -> "900", "grader-cpu" -> "2")),
"stackoverflow" -> Assignment(
packageName = "stackoverflow",
key = "7ByAoS4kEea1yxIfJA1CUw",
itemId = "FWGnz",
partId = "OY5fJ",
maxScore = 10d,
styleScoreRatio = 0.0,
dependencies = depsSpark,
options = Map("Xmx"->"1540m", "grader-memory"->"2048", "totalTimeout" -> "900", "grader-cpu" -> "2")),
"timeusage" -> Assignment(
packageName = "timeusage",
key = "mVk0fgQ0EeeGZQrYVAT1jg",
itemId = "T19Ec",
partId = "y8PO8",
maxScore = 10d,
styleScoreRatio = 0.0,
dependencies = depsSpark :+ ("org.apache.spark" %% "spark-sql" % "2.1.0"),
options = Map("Xmx"->"1540m", "grader-memory"->"2048", "totalTimeout" -> "900", "grader-cpu" -> "2"))
)
}
testOptions in Test := Seq(
Tests.Filter(s => {
// println(s"$s = ${assignment.value}")
s.contains(assignment.value)
})
)