From 0572c3f97fd146071881da74f815df50f7861ebe Mon Sep 17 00:00:00 2001 From: Brice Jaglin Date: Wed, 24 Apr 2024 23:07:48 +0200 Subject: [PATCH] guard current cache invalidation behavior with --settings --- src/sbt-test/skip-windows/caching/test | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/sbt-test/skip-windows/caching/test b/src/sbt-test/skip-windows/caching/test index 69abd4ba..dfe6b223 100644 --- a/src/sbt-test/skip-windows/caching/test +++ b/src/sbt-test/skip-windows/caching/test @@ -162,6 +162,17 @@ $ copy-file files/Null.scala src/main/scala/InitiallyValid.scala -> scalafix --check $ delete src/main/scala +# files should be re-checked if custom rule configuration is added or removed from the CLI (even if the rule is the same) +> set scalafixConfig := Some(file("files/DisableSyntaxVar.scalafix.conf")) +$ mkdir src/main/scala +$ copy-file files/Null.scala src/main/scala/ValidWithoutCustomSettings.scala +-> scalafix --check --settings.DisableSyntax.noNulls=true +> scalafix --check +-> scalafix --check --settings.DisableSyntax.noNulls=true +$ exec chmod 000 src/main/scala/ValidWithoutCustomSettings.scala +-> scalafix --check --settings.DisableSyntax.noNulls=true +$ delete src/main/scala + # files should be re-checked after updating the default configuration (even if the rule is the same) > set scalafixConfig := None $ mkdir src/main/scala