forked from stac-utils/stac4s
-
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.
Cross-publish core module (stac-utils#157)
* Add ScalaJS plugin / project * move core src to shared * add a geometry type to js module * reorganize testing code for x-publication * add js tests * fill in geom generators, run js tests * lol just add a `-node` ♥ * get tests to fail (!!) * move spdxid enum to shared * remove unused * upgrade scalajs plugin * fix dependency declarations dependencies with %%% can't be stored in top-level declarations, so they instead need all to live inside settings macros. this moves everything and isolates the jvm deps * prefer scalafix sort imports rule * add OrganizeImports scalafix rule * organize imports * fully separate js and jvm time and meta types * mirror JVM layout with scalajs java.time package * update gitignore * lint * declare scala-java-time dep in the correct place * fix geometry encoder * fix polygon generator * move scala-java-time dependency to Test * Update changelog * make root a cross-project and rely on aggregate * lint * suppress one scapegoat warning * only run sbt-explicit-dependencies against JVM better scala.js support seems low priority: cb372/sbt-explicit-dependencies#27
- Loading branch information
Showing
82 changed files
with
1,193 additions
and
309 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -97,6 +97,7 @@ project/plugins/project/ | |
metals.lock.db | ||
.metals/ | ||
.bloop/ | ||
project/ | ||
|
||
/.env | ||
/.envrc | ||
|
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 @@ | ||
v14.15.0 |
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 |
---|---|---|
@@ -1,4 +1,16 @@ | ||
rules = [ | ||
ProcedureSyntax, | ||
RemoveUnused | ||
] | ||
RemoveUnused, | ||
OrganizeImports | ||
] | ||
|
||
OrganizeImports { | ||
coalesceToWildcardImportThreshold = 2147483647 # Int.MaxValue | ||
expandRelative = true | ||
groupExplicitlyImportedImplicitsSeparately = false | ||
groupedImports = Merge | ||
groups = ["com.azavea.stac4s", "*", "scala.", "re:javax?\\."] | ||
importSelectorsOrder = Ascii | ||
importsOrder = Ascii | ||
removeUnused = true | ||
} |
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 |
---|---|---|
@@ -1,5 +1,4 @@ | ||
version = 2.7.5 | ||
align = more // For pretty alignment. | ||
align = more // For pretty alignment. | ||
maxColumn = 120 | ||
rewrite.rules = [SortImports] | ||
newlines.alwaysBeforeTopLevelStatements = true |
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
17 changes: 17 additions & 0 deletions
17
modules/core-test/js/src/test/scala/com/azavea/stac4s/JsSerDeSpec.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,17 @@ | ||
package com.azavea.stac4s | ||
|
||
import com.azavea.stac4s.geometry.Geometry | ||
import com.azavea.stac4s.testing.JsInstances._ | ||
|
||
import io.circe.testing.{ArbitraryInstances, CodecTests} | ||
import org.scalatest.funsuite.AnyFunSuite | ||
import org.scalatest.matchers.must.Matchers | ||
import org.scalatestplus.scalacheck.Checkers | ||
import org.typelevel.discipline.scalatest.FunSuiteDiscipline | ||
|
||
class JsSerDeSpec extends AnyFunSuite with FunSuiteDiscipline with Checkers with Matchers with ArbitraryInstances { | ||
checkAll("Codec.ItemCollection", CodecTests[ItemCollection].unserializableCodec) | ||
checkAll("Codec.StacItem", CodecTests[StacItem].unserializableCodec) | ||
checkAll("Codec.Geometry", CodecTests[Geometry].unserializableCodec) | ||
|
||
} |
25 changes: 25 additions & 0 deletions
25
modules/core-test/jvm/src/test/scala/com/azavea/stac4s/JvmSerDeSpec.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,25 @@ | ||
package com.azavea.stac4s | ||
|
||
import com.azavea.stac4s.meta._ | ||
import com.azavea.stac4s.testing.JvmInstances._ | ||
import com.azavea.stac4s.types._ | ||
|
||
import geotrellis.vector.Geometry | ||
import io.circe.testing.{ArbitraryInstances, CodecTests} | ||
import org.scalatest.funsuite.AnyFunSuite | ||
import org.scalatest.matchers.must.Matchers | ||
import org.scalatestplus.scalacheck.Checkers | ||
import org.typelevel.discipline.scalatest.FunSuiteDiscipline | ||
|
||
import java.time.Instant | ||
|
||
class JvmSerDeSpec extends AnyFunSuite with FunSuiteDiscipline with Checkers with Matchers with ArbitraryInstances { | ||
checkAll("Codec.ItemCollection", CodecTests[ItemCollection].unserializableCodec) | ||
checkAll("Codec.StacItem", CodecTests[StacItem].unserializableCodec) | ||
checkAll("Codec.Geometry", CodecTests[Geometry].unserializableCodec) | ||
checkAll("Codec.Instant", CodecTests[Instant].unserializableCodec) | ||
checkAll("Codec.StacCollection", CodecTests[StacCollection].unserializableCodec) | ||
checkAll("Codec.StacExtent", CodecTests[StacExtent].unserializableCodec) | ||
checkAll("Codec.TemporalExtent", CodecTests[TemporalExtent].unserializableCodec) | ||
|
||
} |
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
File renamed without changes.
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
Oops, something went wrong.