Skip to content

Commit

Permalink
Merge pull request #1420 from softwaremill/scala-native-scala3
Browse files Browse the repository at this point in the history
Scala native scala3
  • Loading branch information
Pask423 authored Apr 29, 2022
2 parents 30b3b36 + ee715b8 commit 0dd3176
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ lazy val core = (projectMatrix in file("core"))
}
)
.nativePlatform(
scalaVersions = scala2,
scalaVersions = scala2 ++ scala3,
settings = {
commonNativeSettings ++ versioningSchemeSettings ++ List(
Test / publishArtifact := true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -206,14 +206,14 @@ abstract class AbstractCurlBackend[F[_]](monad: MonadError[F], verbose: Boolean)
val array = str
.split("\n")
.filter(_.trim.length > 0)
Seq(array: _*)
.map { line =>
val split = line.split(":", 2)
if (split.size == 2)
Header(split(0).trim, split(1).trim)
else
Header(split(0).trim, "")
}
Seq(array: _*)
}

private lazy val bodyFromResponseAs = new BodyFromResponseAs[F, String, Nothing, Nothing] {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ package sttp.client3
import sttp.client3.testing.SyncHttpTest

class CurlBackendHttpTest extends SyncHttpTest {
override implicit lazy val backend: SttpBackend[Identity, Any] = CurlBackend(verbose = true)
override implicit val backend: SttpBackend[Identity, Any] = CurlBackend(verbose = true)
}
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
package sttp.client3.testing

import org.scalatest.freespec.AnyFreeSpecLike
import sttp.client3._
import sttp.model.{Header, StatusCode}

import java.io.File
import java.nio.file.Files
import java.security.MessageDigest

trait SyncHttpTestExtensions {
trait SyncHttpTestExtensions extends AnyFreeSpecLike {
self: SyncHttpTest =>

// browsers do not allow access to redirect responses
Expand Down

0 comments on commit 0dd3176

Please sign in to comment.