Skip to content

Commit

Permalink
Test line-trailing infix after xml block
Browse files Browse the repository at this point in the history
  • Loading branch information
kitbellew committed Sep 28, 2024
1 parent f3ad969 commit 18fea6a
Show file tree
Hide file tree
Showing 4 changed files with 125 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9632,3 +9632,33 @@ class UDFRegistration {
).toOption :: Nil
}
}
<<< #4133 infix after xml block
maxColumn = 80
===
object a {
private def waitingBatchRow(batch: BatchUIData): Seq[Node] = {
baseRow(batch) ++ createOutputOperationProgressBar(batch) ++ <td>queued</td>++ {
if (firstFailureReason.nonEmpty) {
// Waiting batches have not run yet, so must have no failure reasons.
<td>-</td>
} else {
Nil
}
}
}
}
>>>
object a {
private def waitingBatchRow(batch: BatchUIData): Seq[Node] = {
baseRow(batch) ++ createOutputOperationProgressBar(
batch
) ++ <td>queued</td> ++ {
if (firstFailureReason.nonEmpty) {
// Waiting batches have not run yet, so must have no failure reasons.
<td>-</td>
} else {
Nil
}
}
}
}
27 changes: 27 additions & 0 deletions scalafmt-tests/shared/src/test/resources/newlines/source_fold.stat
Original file line number Diff line number Diff line change
Expand Up @@ -9035,3 +9035,30 @@ class UDFRegistration {
.toOption :: Nil
}
}
<<< #4133 infix after xml block
maxColumn = 80
===
object a {
private def waitingBatchRow(batch: BatchUIData): Seq[Node] = {
baseRow(batch) ++ createOutputOperationProgressBar(batch) ++ <td>queued</td>++ {
if (firstFailureReason.nonEmpty) {
// Waiting batches have not run yet, so must have no failure reasons.
<td>-</td>
} else {
Nil
}
}
}
}
>>>
object a {
private def waitingBatchRow(batch: BatchUIData): Seq[Node] = {
baseRow(batch) ++ createOutputOperationProgressBar(batch) ++
<td>queued</td> ++ {
if (firstFailureReason.nonEmpty) {
// Waiting batches have not run yet, so must have no failure reasons.
<td>-</td>
} else { Nil }
}
}
}
30 changes: 30 additions & 0 deletions scalafmt-tests/shared/src/test/resources/newlines/source_keep.stat
Original file line number Diff line number Diff line change
Expand Up @@ -9429,3 +9429,33 @@ class UDFRegistration {
).toOption :: Nil
}
}
<<< #4133 infix after xml block
maxColumn = 80
===
object a {
private def waitingBatchRow(batch: BatchUIData): Seq[Node] = {
baseRow(batch) ++ createOutputOperationProgressBar(batch) ++ <td>queued</td>++ {
if (firstFailureReason.nonEmpty) {
// Waiting batches have not run yet, so must have no failure reasons.
<td>-</td>
} else {
Nil
}
}
}
}
>>>
object a {
private def waitingBatchRow(batch: BatchUIData): Seq[Node] = {
baseRow(batch) ++ createOutputOperationProgressBar(
batch
) ++ <td>queued</td> ++ {
if (firstFailureReason.nonEmpty) {
// Waiting batches have not run yet, so must have no failure reasons.
<td>-</td>
} else {
Nil
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9710,3 +9710,41 @@ class UDFRegistration {
.toOption :: Nil
}
}
<<< #4133 infix after xml block
maxColumn = 80
===
object a {
private def waitingBatchRow(batch: BatchUIData): Seq[Node] = {
baseRow(batch) ++ createOutputOperationProgressBar(batch) ++ <td>queued</td>++ {
if (firstFailureReason.nonEmpty) {
// Waiting batches have not run yet, so must have no failure reasons.
<td>-</td>
} else {
Nil
}
}
}
}
>>>
Idempotency violated
=> Diff (- obtained, + expected)
private def waitingBatchRow(batch: BatchUIData): Seq[Node] = {
- baseRow(batch) ++ createOutputOperationProgressBar(batch) ++ <td>queued</td>
- ++ {
- if (firstFailureReason.nonEmpty) {
- // Waiting batches have not run yet, so must have no failure reasons.
- <td>-</td>
- } else {
- Nil
+ baseRow(batch) ++ createOutputOperationProgressBar(batch) ++
+ <td>queued</td>
+ ++ {
+ if (firstFailureReason.nonEmpty) {
+ // Waiting batches have not run yet, so must have no failure reasons.
+ <td>-</td>
+ } else {
+ Nil
+ }
}
- }
}

0 comments on commit 18fea6a

Please sign in to comment.