Skip to content

Commit 1c98afa

Browse files
committed
fix testing of scalafixDependencies alongside local rules
555d1f3 removed it accidentally
1 parent e2a17b4 commit 1c98afa

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/sbt-test/sbt-scalafix/local-rules/build.sbt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ import _root_.scalafix.sbt.{BuildInfo => Versions}
33
inThisBuild(
44
List(
55
scalafixDependencies := List(
6-
// Custom rule cross-published to Maven Central https://github.com/scalacenter/example-scalafix-rule
7-
"ch.epfl.scala" %% "example-scalafix-rule" % "1.4.0"
6+
// CollectHead
7+
"com.github.xuwei-k" %% "scalafix-rules" % "0.6.5"
88
),
99
resolvers += Resolver.sonatypeRepo("snapshots"),
1010
// out of sync with scalafix.sbt.BuildInfo.scala213 on purpose
@@ -13,6 +13,7 @@ inThisBuild(
1313
)
1414
)
1515

16+
// LocalSyntacticRule
1617
val rules = project
1718
.disablePlugins(ScalafixPlugin)
1819
.settings(
@@ -23,9 +24,11 @@ val rules = project
2324
val service = project
2425
.dependsOn(rules % ScalafixConfig)
2526
.settings(
27+
// SyntacticRule
2628
libraryDependencies += "ch.epfl.scala" %% "example-scalafix-rule" % "3.0.0" % ScalafixConfig
2729
)
2830

31+
// SameProjectSyntacticRule
2932
val sameproject = project
3033
.settings(
3134
libraryDependencies += "ch.epfl.scala" %% "scalafix-core" % Versions.scalafixVersion % ScalafixConfig

src/sbt-test/sbt-scalafix/local-rules/test

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ $ delete rules/src/main/scala/local/NoOp.scala
77
-> service / scalafix LocalSyntacticRule
88

99
# make sure scalafixDependencies is also honored by running a rule from a remote JAR
10-
> service / scalafix SyntacticRule
10+
> service / scalafix CollectHead
1111

1212
# run a rule included from a remote JAR referenced via the Scalafix ivy config
1313
> service / scalafix SyntacticRule

0 commit comments

Comments
 (0)