1 import type { ItemRevision, ItemType } from '@proton/pass/types';
2 import { ContentFormatVersion, ItemState } from '@proton/pass/types';
3 import { uniqueId } from '@proton/pass/utils/string/unique-id';
4 import { getEpoch } from '@proton/pass/utils/time/epoch';
6 import { itemBuilder } from './item.builder';
8 export const createTestItem = (type: ItemType, init: Partial<ItemRevision> = {}): ItemRevision => ({
10 contentFormatVersion: ContentFormatVersion.Item,
11 createTime: getEpoch(),
13 lastUseTime: getEpoch(),
14 modifyTime: getEpoch(),
18 revisionTime: getEpoch(),
19 state: ItemState.Active,
20 data: itemBuilder(type).data,