feat: sites and authors integration into existing screens (& formated all frontend files kinda accidentally)
This commit is contained in:
1 parent
3d81d2c717
commit
6b8990c55e
239 files changed
+9194
-1354
No files matched your search
@@ -0,0 +1,18 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import { baseSlugOf } from '@/lib/authorProfile'
|
||||
|
||||
describe('The base slug of an adjusted slug', () => {
|
||||
it.each([
|
||||
['marta-alves-2', 'marta-alves'],
|
||||
['ines-duarte-3', 'ines-duarte'],
|
||||
['jean-luc-o-neil-2', 'jean-luc-o-neil'],
|
||||
['agent-007-2', 'agent-007'],
|
||||
['zoe-muller-12', 'zoe-muller'],
|
||||
])('strips the one collision suffix of "%s"', (slug, base) => {
|
||||
expect(baseSlugOf(slug)).toBe(base)
|
||||
})
|
||||
|
||||
it('leaves a slug without a numeric suffix alone', () => {
|
||||
expect(baseSlugOf('marta-alves')).toBe('marta-alves')
|
||||
})
|
||||
})
|
||||
Reference in new issue
Block a user