All files / libs/kernel/testing/server/bed/src/test-utils/fixtures/amalia ruleAssignment.ts

100% Statements 73/73
100% Branches 0/0
100% Functions 0/0
100% Lines 73/73

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 741x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x  
import { faker } from '@faker-js/faker';
 
import { type RuleAssignment } from '@amalia/core/models';
import { HidableElementVisibility } from '@amalia/payout-definition/plans/types';
 
import { company } from './company';
import { plans } from './plans';
import { rules } from './rules';
 
export const ruleAssignments = [
  {
    id: 'eca4c4a5-d8ab-4539-ba74-ea8066b55a25',
    planId: plans.planScopedOverwrites.id,
    ruleId: rules.recordRule.id,
    kpisToDisplay: [],
    plan: plans.planScopedOverwrites,
    rule: rules.recordRule,
    company,
    category: null,
    index: 0,
    createdAt: new Date(),
    updatedAt: new Date(),
  },
  {
    id: '2ea3c42b-35eb-4e2b-911b-2dae9c28628f',
    planId: plans.planWithRule.id,
    ruleId: rules.amaliaRule.id,
    kpisToDisplay: [
      {
        id: faker.string.uuid(),
        kpis: [
          {
            id: '93588257-b13b-4bb1-8e19-606678437a07',
            displayStatus: HidableElementVisibility.ON_DISPLAY,
          },
        ],
      },
    ],
    index: 0,
    plan: plans.planWithRule,
    rule: rules.amaliaRule,
    company,
    category: null,
    createdAt: new Date(),
    updatedAt: new Date(),
  },
  {
    id: '963bef46-2ce2-4cc6-be2a-d4c858601b89',
    planId: plans.planToTestPlanAgreement.id,
    ruleId: rules.amaliaRule.id,
    index: 0,
    kpisToDisplay: [],
    category: null,
    company,
    createdAt: new Date(),
    updatedAt: new Date(),
    plan: plans.planToTestPlanAgreement,
    rule: rules.amaliaRule,
  },
  {
    id: '919076a0-b5c8-42a4-933f-80e66c2274de',
    planId: plans.planToTestPlanAgreement.id,
    ruleId: rules.amaliaRule2.id,
    index: 1,
    kpisToDisplay: [],
    category: null,
    company,
    createdAt: new Date(),
    updatedAt: new Date(),
    plan: plans.planToTestPlanAgreement,
    rule: rules.amaliaRule2,
  },
] as const satisfies RuleAssignment[];