vikunja-frontend/cypress/factories/link_sharing.js
Dominik Pschenitschni 6db0559b81 fix: replace faker with community fork faker-js/faker (#1408)
Co-authored-by: Dominik Pschenitschni <mail@celement.de>
Reviewed-on: https://kolaente.dev/vikunja/frontend/pulls/1408
Reviewed-by: konrad <k@knt.li>
Co-authored-by: Dominik Pschenitschni <dpschen@noreply.kolaente.de>
Co-committed-by: Dominik Pschenitschni <dpschen@noreply.kolaente.de>
2022-01-20 07:54:39 +00:00

22 lines
437 B
JavaScript

import {Factory} from '../support/factory'
import {formatISO} from "date-fns"
import faker from '@faker-js/faker'
export class LinkShareFactory extends Factory {
static table = 'link_shares'
static factory() {
const now = new Date()
return {
id: '{increment}',
hash: faker.random.word(32),
list_id: 1,
right: 0,
sharing_type: 0,
shared_by_id: 1,
created: formatISO(now),
updated: formatISO(now)
}
}
}