Skip to content

Commit

Permalink
chore: change key
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinSchoeler committed Dec 23, 2024
1 parent fe21aea commit b89874f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion apps/meteor/client/components/dashboards/periods.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ const periods = [
range: lastNDays(getLast6Months()),
},
{
key: 'last year',
key: 'this year',
label: label('This_year'),
range: lastNDays(moment().dayOfYear()),
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,4 @@ export const COLORS = {
warning2: Palette.statusColor['status-font-on-warning-2'].toString(),
};

export const PERIOD_OPTIONS: Period['key'][] = ['today', 'this week', 'last 15 days', 'this month', 'last 6 months', 'last year'];
export const PERIOD_OPTIONS: Period['key'][] = ['today', 'this week', 'last 15 days', 'this month', 'last 6 months', 'this year'];
8 changes: 4 additions & 4 deletions apps/meteor/tests/e2e/omnichannel/omnichannel-reports.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,12 +90,12 @@ test.describe.serial('Omnichannel Reports', () => {
await route.fulfill({ response, json: mock });
});

await poReports.statusSection.selectPeriod('last year');
await poReports.statusSection.selectPeriod('this year');
await expect(poReports.statusSection.legendItem(`Closed 25 (25%)`)).toBeVisible();
await expect(poReports.statusSection.legendItem(`Open 25 (25%)`)).toBeVisible();
await expect(poReports.statusSection.legendItem(`Queued 25 (25%)`)).toBeVisible();
await expect(poReports.statusSection.legendItem(`On hold 25 (25%)`)).toBeVisible();
await expect(poReports.statusSection.txtSummary).toHaveText('100 conversations, last year');
await expect(poReports.statusSection.txtSummary).toHaveText('100 conversations, this year');
});
});

Expand Down Expand Up @@ -145,10 +145,10 @@ test.describe.serial('Omnichannel Reports', () => {
await route.fulfill({ response, json: mock });
});

await poReports.channelsSection.selectPeriod('last year');
await poReports.channelsSection.selectPeriod('this year');
await expect(poReports.channelsSection.legendItem(`Channel 1 50 (50%)`)).toBeVisible();
await expect(poReports.channelsSection.legendItem(`Channel 2 50 (50%)`)).toBeVisible();
await expect(poReports.channelsSection.txtSummary).toHaveText('100 conversations, last year');
await expect(poReports.channelsSection.txtSummary).toHaveText('100 conversations, this year');
});

await test.step('More than 5 channels', async () => {
Expand Down

0 comments on commit b89874f

Please sign in to comment.