mirror of
https://github.com/tomru/pfadi-bussle.git
synced 2026-03-04 06:57:12 +01:00
show booking date in mails
This commit is contained in:
12
helpers/date.test.ts
Normal file
12
helpers/date.test.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { daysFormatFrontend } from './date'
|
||||
|
||||
test('daysFormatFrontend', () => {
|
||||
expect(daysFormatFrontend([])).toEqual('')
|
||||
expect(daysFormatFrontend(['2020-01-01'])).toEqual('01.01.2020')
|
||||
expect(daysFormatFrontend(['2020-01-01', '2020-01-02'])).toEqual(
|
||||
'01.01.2020-02.01.2020'
|
||||
)
|
||||
expect(
|
||||
daysFormatFrontend(['2020-01-01', '2020-01-02', '2020-01-05'])
|
||||
).toEqual('01.01.2020-05.01.2020')
|
||||
})
|
||||
Reference in New Issue
Block a user