Skip to content

Commit a959aa6

Browse files
committed
Upgrade to CoffeeScript 1.11.0
1 parent 91b45fa commit a959aa6

File tree

6 files changed

+34
-41
lines changed

6 files changed

+34
-41
lines changed

build.sbt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
organization := "com.typesafe.sbt"
22
name := "sbt-coffeescript"
33
libraryDependencies ++= Seq(
4-
"org.webjars" % "coffee-script-node" % "1.7.1",
5-
"org.webjars" % "mkdirp" % "0.3.5"
4+
"org.webjars" % "coffee-script-node" % "1.11.0",
5+
"org.webjars" % "mkdirp" % "0.5.0"
66
)
77
addSbtJsEngine("1.2.1")

src/sbt-test/sbt-coffeescript-plugin/coffee/build.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ checkMapFileContents := {
1212
| "a.coffee"
1313
| ],
1414
| "names": [],
15-
| "mappings": "AAAA;AAAA,MAAA,gBAAA;;AAAA,EAAA,MAAA,GAAW,EAAX,CAAA;;AAAA,EACA,QAAA,GAAW,IADX,CAAA;AAAA"
15+
| "mappings": "AAAA;AAAA,MAAA;;EAAA,MAAA,GAAW;;EACX,QAAA,GAAW;AADX"
1616
|}""".stripMargin) {
1717
sys.error(s"Unexpected contents: $contents")
1818
}
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
lazy val root = (project in file(".")).enablePlugins(SbtWeb)
2+
3+
WebKeys.reporter := {
4+
val logFile = target.value / "test-errors.log"
5+
new LoggerReporter(-1, new Logger {
6+
7+
def trace(t: => Throwable): Unit = {}
8+
9+
def success(message: => String): Unit = {}
10+
11+
def log(level: Level.Value, message: => String): Unit = {
12+
if (level == Level.Error) {
13+
IO.append(logFile, message + "\n")
14+
}
15+
}
16+
})
17+
}
18+
19+
val checkTestErrorLogContents = taskKey[Unit]("check that test log contents are correct")
20+
checkTestErrorLogContents := {
21+
val contents = IO.read(target.value / "test-errors.log")
22+
if (!contents.endsWith("""src/sbt-test/sbt-coffeescript-plugin/error-output/src/main/assets/a.coffee:0: unexpected %
23+
|%
24+
|^
25+
|one error found
26+
|""".stripMargin)) {
27+
sys.error(s"Unexpected contents: $contents")
28+
}
29+
}

src/sbt-test/sbt-coffeescript-plugin/error-output/project/TestBuild.scala

Lines changed: 0 additions & 36 deletions
This file was deleted.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
*(U$@QNJH#R)
1+
%
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# Compile an less file and see that errors are reported.
22
-> assets
3-
$ exists target/unrecognised-input-error
3+
> checkTestErrorLogContents

0 commit comments

Comments
 (0)