-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add and test (kind of) task for http persistence * Remove local network url from build.sbt * Update README * Update README * fix implicit without type annotation (scala 3 error) * set subproject names to nicer values * run tests with cross scala versions * correct plugin dep name in scripted tests * remove note about untested js implementation the app tests only verify that, when talking to an actual postgres database, the magic skunk strings are correct. those strings are shared, so the database interaction is tested in JS in one sense (barring any really weird skunk regressions that somehow aren't caught upstream -- this is almost an impossibility I think). also, testing the JS app is included in the ci-test command, it's just that there aren't currently any tests that get executed as part of it. if there are in the future though, they'll be tested, and invoking the test command even without any tests still at least cross-compiles the sjs code with scala 2.13 and scala 3. * Update README.md Co-authored-by: Juan Pedro Moreno <[email protected]> Co-authored-by: Juan Pedro Moreno <[email protected]>
- Loading branch information
1 parent
1922950
commit 351df9a
Showing
13 changed files
with
265 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
energy-monitor-plugin/src/sbt-test/sbt-energymonitor/http-store/build.sbt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
version := "0.1" | ||
scalaVersion := "2.13.8" | ||
|
||
lazy val httpTest = (project in file(".")) | ||
.settings( | ||
libraryDependencies += "org.scalatest" %% "scalatest" % "3.2.12" % Test | ||
) |
1 change: 1 addition & 0 deletions
1
energy-monitor-plugin/src/sbt-test/sbt-energymonitor/http-store/project/build.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
sbt.version=1.6.2 |
1 change: 1 addition & 0 deletions
1
energy-monitor-plugin/src/sbt-test/sbt-energymonitor/http-store/project/lib/jRAPL-1.0.jar
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../../../../lib/jRAPL-1.0.jar |
9 changes: 9 additions & 0 deletions
9
energy-monitor-plugin/src/sbt-test/sbt-energymonitor/http-store/project/plugins.sbt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
val pluginVersion = System.getProperty("plugin.version") | ||
if (pluginVersion == null) | ||
throw new RuntimeException( | ||
"""|The system property 'plugin.version' is not defined. | ||
|Specify this property using the scriptedLaunchOpts -D.""".stripMargin | ||
) | ||
else addSbtPlugin("com.47deg" % """energy-monitor-plugin""" % pluginVersion) | ||
} |
18 changes: 18 additions & 0 deletions
18
energy-monitor-plugin/src/sbt-test/sbt-energymonitor/http-store/src/main/scala/Main.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package simple | ||
|
||
/** A simple class and objects to write tests against. | ||
*/ | ||
class Main { | ||
val default = "the function returned" | ||
def method = default + " " + Main.function | ||
} | ||
|
||
object Main { | ||
|
||
val constant = 1 | ||
def function = 2 * constant | ||
|
||
def main(args: Array[String]): Unit = { | ||
println(new Main().default) | ||
} | ||
} |
Oops, something went wrong.