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

Format Scala files in codesig test cases #3323

Merged
merged 2 commits into from
Jul 31, 2024
Merged

Format Scala files in codesig test cases #3323

merged 2 commits into from
Jul 31, 2024

Conversation

lefou
Copy link
Member

@lefou lefou commented Jul 30, 2024

Newer versions of Mill better find these nested modules (#3270), so that our CI check for formatted Scala files will fail once we bump to Mill 0.11.10 or newer.

@lihaoyi
Copy link
Member

lihaoyi commented Jul 31, 2024

The tests are failing because the test framework scrapes the /* */ comment to find the expected assertion data. Should be easy to tweak the scraping (Should be

val openTagLine = s"/* $tag"
sourceLinesOpt.flatMap { sourceLines =>
sourceLines.count(_ == openTagLine) match {
case 0 => None
case 1 =>
val expectedLines = sourceLines
.dropWhile(_ != openTagLine)
.drop(1)
.takeWhile(_ != "*/")
) to accomadate the adjusted format.

@lefou lefou merged commit 1f3fb55 into main Jul 31, 2024
39 checks passed
@lefou lefou deleted the format-scala branch July 31, 2024 09:09
@lefou lefou modified the milestones: 0.11.12, 0.11.11 Jul 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants