---
source: crates/ruff_python_formatter/tests/fixtures.rs
input_file: crates/ruff_python_formatter/resources/test/fixtures/black/cases/pattern_matching_trailing_comma.py
snapshot_kind: text
---
## Input

```python
match maybe, multiple:
    case perhaps, 5:
        pass
    case perhaps, 6,:
        pass


match more := (than, one), indeed,:
    case _, (5, 6):
        pass
    case [[5], (6)], [7],:
        pass
    case _:
        pass
```

## Black Differences

```diff
--- Black
+++ Ruff
@@ -8,13 +8,16 @@
         pass
 
 
-match more := (than, one), indeed,:
+match (
+    more := (than, one),
+    indeed,
+):
     case _, (5, 6):
         pass
-    case (
+    case [
         [[5], (6)],
         [7],
-    ):
+    ]:
         pass
     case _:
         pass
```

## Ruff Output

```python
match maybe, multiple:
    case perhaps, 5:
        pass
    case (
        perhaps,
        6,
    ):
        pass


match (
    more := (than, one),
    indeed,
):
    case _, (5, 6):
        pass
    case [
        [[5], (6)],
        [7],
    ]:
        pass
    case _:
        pass
```

## Black Output

```python
match maybe, multiple:
    case perhaps, 5:
        pass
    case (
        perhaps,
        6,
    ):
        pass


match more := (than, one), indeed,:
    case _, (5, 6):
        pass
    case (
        [[5], (6)],
        [7],
    ):
        pass
    case _:
        pass
```
