Skip to content

Commit 95516c8

Browse files
committed
Updating test data for 2.0.0 due to new defaults align.openParenDefnSite
1 parent 305fc45 commit 95516c8

File tree

3 files changed

+45
-2
lines changed

3 files changed

+45
-2
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
@foobar("annot", {
2+
val x = 2
3+
val y = 2 // y=2
4+
x + y
5+
})
6+
object a extends b with c {
7+
def foo[T: Int#Double#Triple, R <% String](
8+
@annot1
9+
x: Int @annot2 = 2,
10+
y: Int = 3
11+
): Int = {
12+
"match" match {
13+
case 1 | 2 =>
14+
3
15+
case <A>2</A> => 2
16+
}
17+
}
18+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
@foobar("annot", {
2+
val x = 2
3+
val y = 2 // y=2
4+
x + y
5+
})
6+
object a
7+
extends b
8+
with c {
9+
def foo[
10+
T: Int#Double#Triple,
11+
R <% String
12+
](
13+
@annot1
14+
x: Int @annot2 =
15+
2,
16+
y: Int = 3
17+
): Int = {
18+
"match" match {
19+
case 1 | 2 =>
20+
3
21+
case <A>2</A> =>
22+
2
23+
}
24+
}
25+
}

testlib/src/test/java/com/diffplug/spotless/scala/ScalaFmtStepTest.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,14 +45,14 @@ public void behaviorCustomConfig() throws Exception {
4545
public void behaviorDefaultConfigVersion_2_0_0() throws Exception {
4646
FormatterStep step = ScalaFmtStep.create("2.0.0", TestProvisioner.mavenCentral(), null);
4747
StepHarness.forStep(step)
48-
.testResource("scala/scalafmt/basic.dirty", "scala/scalafmt/basic.clean");
48+
.testResource("scala/scalafmt/basic.dirty", "scala/scalafmt/basicPost2.0.0.clean");
4949
}
5050

5151
@Test
5252
public void behaviorCustomConfigVersion_2_0_0() throws Exception {
5353
FormatterStep step = ScalaFmtStep.create("2.0.0", TestProvisioner.mavenCentral(), createTestFile("scala/scalafmt/scalafmt.conf"));
5454
StepHarness.forStep(step)
55-
.testResource("scala/scalafmt/basic.dirty", "scala/scalafmt/basic.cleanWithCustomConf");
55+
.testResource("scala/scalafmt/basic.dirty", "scala/scalafmt/basicPost2.0.0.cleanWithCustomConf");
5656
}
5757

5858
@Test

0 commit comments

Comments
 (0)