mirror of https://github.com/sbt/sbt.git
Merge pull request #4473 from eed3si9n/wip/bump
bump util, lm, and zinc
This commit is contained in:
commit
f6031709c8
|
|
@ -10,7 +10,7 @@ def buildLevelSettings: Seq[Setting[_]] =
|
|||
inThisBuild(
|
||||
Seq(
|
||||
organization := "org.scala-sbt",
|
||||
version := "1.2.1-SNAPSHOT",
|
||||
version := "1.2.7-SNAPSHOT",
|
||||
description := "sbt is an interactive build tool",
|
||||
bintrayOrganization := Some("sbt"),
|
||||
bintrayRepository := {
|
||||
|
|
|
|||
|
|
@ -10,9 +10,9 @@ object Dependencies {
|
|||
|
||||
// sbt modules
|
||||
private val ioVersion = "1.2.2"
|
||||
private val utilVersion = "1.2.3"
|
||||
private val lmVersion = "1.2.2"
|
||||
private val zincVersion = "1.2.4"
|
||||
private val utilVersion = "1.2.4"
|
||||
private val lmVersion = "1.2.3"
|
||||
private val zincVersion = "1.2.5"
|
||||
|
||||
private val sbtIO = "org.scala-sbt" %% "io" % ioVersion
|
||||
|
||||
|
|
|
|||
|
|
@ -19,11 +19,11 @@ import scala.collection.parallel.ForkJoinTaskSupport
|
|||
import scala.util.control.NonFatal
|
||||
import sbt.internal.scripted._
|
||||
import sbt.internal.io.Resources
|
||||
import sbt.internal.util.{ BufferedLogger, ConsoleLogger, FullLogger }
|
||||
import sbt.internal.util.{ BufferedLogger, FullLogger, ConsoleOut }
|
||||
import sbt.io.syntax._
|
||||
import sbt.io.{ DirectoryFilter, HiddenFileFilter, IO }
|
||||
import sbt.io.FileFilter._
|
||||
import sbt.util.{ AbstractLogger, Logger }
|
||||
import sbt.util.{ AbstractLogger, Level, Logger }
|
||||
|
||||
final class ScriptedTests(
|
||||
resourceBaseDirectory: File,
|
||||
|
|
@ -449,7 +449,7 @@ object ScriptedTests extends ScriptedRunner {
|
|||
// val buildScalaVersions = args(4)
|
||||
val bootProperties = new File(args(5))
|
||||
val tests = args.drop(6)
|
||||
val logger = ConsoleLogger()
|
||||
val logger = TestConsoleLogger()
|
||||
run(directory, buffer, tests, logger, bootProperties, Array(), emptyCallback)
|
||||
}
|
||||
|
||||
|
|
@ -467,7 +467,7 @@ class ScriptedRunner {
|
|||
launchOpts: Array[String],
|
||||
prescripted: java.util.List[File],
|
||||
): Unit = {
|
||||
val logger = ConsoleLogger()
|
||||
val logger = new TestConsoleLogger()
|
||||
val addTestFile = (f: File) => { prescripted.add(f); () }
|
||||
run(resourceBaseDirectory, bufferLog, tests, logger, bootProperties, launchOpts, addTestFile)
|
||||
//new FullLogger(Logger.xlog2Log(log)))
|
||||
|
|
@ -481,7 +481,7 @@ class ScriptedRunner {
|
|||
bootProperties: File,
|
||||
launchOpts: Array[String],
|
||||
): Unit = {
|
||||
val logger = ConsoleLogger()
|
||||
val logger = TestConsoleLogger()
|
||||
val prescripted = ScriptedTests.emptyCallback
|
||||
run(resourceBaseDirectory, bufferLog, tests, logger, bootProperties, launchOpts, prescripted)
|
||||
}
|
||||
|
|
@ -529,7 +529,7 @@ class ScriptedRunner {
|
|||
prescripted: java.util.List[File],
|
||||
instances: Int
|
||||
): Unit = {
|
||||
val logger = ConsoleLogger()
|
||||
val logger = TestConsoleLogger()
|
||||
val addTestFile = (f: File) => { prescripted.add(f); () }
|
||||
runInParallel(baseDir, bufferLog, tests, logger, bootProps, launchOpts, addTestFile, instances)
|
||||
}
|
||||
|
|
@ -652,3 +652,32 @@ class PendingTestSuccessException(label: String) extends Exception {
|
|||
override def getMessage: String =
|
||||
s"The pending test $label succeeded. Mark this test as passing to remove this failure."
|
||||
}
|
||||
|
||||
private[sbt] object TestConsoleLogger {
|
||||
def apply() = new TestConsoleLogger()
|
||||
}
|
||||
|
||||
// Remove dependencies to log4j to avoid mixup.
|
||||
private[sbt] class TestConsoleLogger extends AbstractLogger {
|
||||
val out = ConsoleOut.systemOut
|
||||
def trace(t: => Throwable): Unit = {
|
||||
out.println(t.toString)
|
||||
// out.flush()
|
||||
}
|
||||
def success(message: => String): Unit = {
|
||||
out.println(message)
|
||||
// out.flush()
|
||||
}
|
||||
def log(level: Level.Value, message: => String): Unit = {
|
||||
out.println(s"[$level] $message")
|
||||
// out.flush()
|
||||
}
|
||||
def control(event: sbt.util.ControlEvent.Value, message: => String): Unit = ()
|
||||
def getLevel: sbt.util.Level.Value = Level.Info
|
||||
def getTrace: Int = Int.MaxValue
|
||||
def logAll(events: Seq[sbt.util.LogEvent]): Unit = ()
|
||||
def setLevel(newLevel: sbt.util.Level.Value): Unit = ()
|
||||
def setSuccessEnabled(flag: Boolean): Unit = ()
|
||||
def setTrace(flag: Int): Unit = ()
|
||||
def successEnabled: Boolean = true
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue