Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update scalafmt-core to 3.8.5 #467

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,6 @@

# Scala Steward: Reformat with scalafmt 3.6.1
fa49859eb2585640b5ed6f1c9cc7c64923bc1a15

# Scala Steward: Reformat with scalafmt 3.8.5
6f13a983a4f12b69820f2b040cad05e68836cef0
2 changes: 1 addition & 1 deletion .scalafmt.conf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version = 3.8.3
version = 3.8.5
runner.dialect = scala213
continuationIndent.defnSite = 2
docstrings.style = Asterisk
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
}

it should "parse aliases" in {
it should "parse aliases" in
assert(
Parser
.parse(
Expand All @@ -99,7 +99,6 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
.isRight
)
}

"Parser.parseDocuments" should "fail on invalid tagged numbers" in {
val result = parser.parseDocuments(new StringReader("!!int 12foo")).toList
Expand Down Expand Up @@ -177,7 +176,7 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
}

it should "parse when within code point limit" in {
it should "parse when within code point limit" in
assert(
Parser // 1MB
.parse(
Expand All @@ -189,6 +188,5 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
.isRight
)
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,10 @@ class EscapingTests extends AnyFlatSpec with Matchers with ScalaCheckDrivenPrope
parse(s1) shouldBe Right(json)
}

it should "properly escape JSON string values" in {
it should "properly escape JSON string values" in
forAll { (s0: String) =>
test2(s0)
}
}

def test3(c: Char): Unit = {
val m = Map(c.toString -> c.toInt)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
}

it should "fail to parse too many aliases" in {
it should "fail to parse too many aliases" in
assert(
Parser
.make(Parser.Config(maxAliasesForCollections = 1))
Expand All @@ -139,7 +139,6 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
.isLeft
)
}

"Parser.parseDocuments" should "fail on invalid tagged numbers" in {
val result = parser.parseDocuments(new StringReader("!!int 12foo")).toList
Expand Down Expand Up @@ -250,7 +249,7 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
}

it should "fail to parse when code point limit is exceeded" in {
it should "fail to parse when code point limit is exceeded" in
assert(
Parser
.make(Parser.Config(codePointLimit = 13)) // 13B
Expand All @@ -262,5 +261,4 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
.isLeft
)
}
}
9 changes: 3 additions & 6 deletions circe-yaml/src/test/scala/io/circe/yaml/EscapingTests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,9 @@ class EscapingTests extends AnyFlatSpec with Matchers with ScalaCheckDrivenPrope
repr(Try(parse(s))) shouldBe repr(Success(Right(json)))
}

"Escaping" should "properly escape JSON string values (all chars)" in {
"Escaping" should "properly escape JSON string values (all chars)" in
// exhaustive test: 65k test cases
(Char.MinValue to Char.MaxValue).map(_.toChar).foreach(test1)
}

def test2(s0: String): Unit = {
val json = s0.asJson
Expand All @@ -66,11 +65,10 @@ class EscapingTests extends AnyFlatSpec with Matchers with ScalaCheckDrivenPrope
parse(s1) shouldBe Right(json)
}

it should "properly escape JSON string values" in {
it should "properly escape JSON string values" in
forAll { (s0: String) =>
test2(s0)
}
}

def test3(c: Char): Unit = {
val m = Map(c.toString -> c.toInt)
Expand All @@ -79,8 +77,7 @@ class EscapingTests extends AnyFlatSpec with Matchers with ScalaCheckDrivenPrope
parser.parse(printer.print(o)).right.flatMap(_.as[Map[String, Int]]) shouldBe Right(m)
}

it should "properly escape JSON object keys" in {
it should "properly escape JSON object keys" in
// exhaustive test: 65k test cases
(Char.MinValue to Char.MaxValue).map(_.toChar).foreach(test3)
}
}
6 changes: 2 additions & 4 deletions circe-yaml/src/test/scala/io/circe/yaml/ParserTests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
}

it should "fail to parse too many aliases" in {
it should "fail to parse too many aliases" in
assert(
Parser(maxAliasesForCollections = 1)
.parse(
Expand All @@ -137,7 +137,6 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
.isLeft
)
}

"Parser.parseDocuments" should "fail on invalid tagged numbers" in {
val result = parser.parseDocuments(new StringReader("!!int 12foo")).toList
Expand Down Expand Up @@ -274,7 +273,7 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
}

it should "fail to parse when code point limit is exceeded" in {
it should "fail to parse when code point limit is exceeded" in
assert(
Parser(codePointLimit = 13) // 13B
.parse(
Expand All @@ -285,5 +284,4 @@ class ParserTests extends AnyFlatSpec with Matchers with EitherValues {
)
.isLeft
)
}
}
Loading