Skip to content

Commit

Permalink
prepare sbt 2.x in test code (#269)
Browse files Browse the repository at this point in the history
  • Loading branch information
xuwei-k authored Oct 17, 2024
1 parent 374f9ac commit c315cf0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import org.openjdk.jmh.runner.Runner
import org.openjdk.jmh.runner.options.CommandLineOptions

object CustomRunnerApp {
import scala.collection.JavaConversions._
import scala.collection.JavaConverters._

def main(args: Array[String]): Unit = {
val opts = new CommandLineOptions(args: _*) // parse command line arguments, and then bend them to your will! ;-)
Expand All @@ -17,7 +17,7 @@ object CustomRunnerApp {
val results = runner.run() // actually run the benchmarks

val f = new FileOutputStream(new File("custom.out"))
results.foreach { result: RunResult
results.asScala.foreach { (result: RunResult) =>
// usually you'd use these results to report into some external aggregation tool for example
f.write(s"custom reporting result: ${result.getAggregatedResult.getPrimaryResult}".getBytes("UTF-8"))
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import org.openjdk.jmh.runner.Runner
import org.openjdk.jmh.runner.options.CommandLineOptions

object CustomRunnerApp {
import scala.collection.JavaConversions._
import scala.collection.JavaConverters._

def main(args: Array[String]): Unit = {
val opts = new CommandLineOptions(args: _*) // parse command line arguments, and then bend them to your will! ;-)
Expand All @@ -17,7 +17,7 @@ object CustomRunnerApp {
val results = runner.run() // actually run the benchmarks

val f = new FileOutputStream(new File("custom.out"))
results.foreach { result: RunResult
results.asScala.foreach { (result: RunResult) =>
// usually you'd use these results to report into some external aggregation tool for example
f.write(s"custom reporting result: ${result.getAggregatedResult.getPrimaryResult}".getBytes("UTF-8"))
}
Expand Down

0 comments on commit c315cf0

Please sign in to comment.