# Find Why a Test Fails

Source: https://coremesh.online/prompts/find-why-a-test-fails/

This Python + pytest test fails:

```
def test_slugify_accents():
    assert slugify('Café Déjà') == 'cafe-deja'
```

Output:
```
AssertionError: assert 'caf-d-j' == 'cafe-deja'
```

Code under test:
```
def slugify(s):
    return re.sub(r'[^a-z0-9]+', '-', s.lower()).strip('-')
```

First decide: is the code wrong, or is the test's expectation wrong? Explain why in two sentences.
Then give the smallest change that fixes the right side, and one extra test case that would have caught this earlier.
Do not weaken or delete the test to make it pass.
