Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/frontend/admin/abuse_reports/components/abuse_report_row_spec.js')
-rw-r--r--spec/frontend/admin/abuse_reports/components/abuse_report_row_spec.js15
1 files changed, 15 insertions, 0 deletions
diff --git a/spec/frontend/admin/abuse_reports/components/abuse_report_row_spec.js b/spec/frontend/admin/abuse_reports/components/abuse_report_row_spec.js
index 03bf510f3ad..8482faccca0 100644
--- a/spec/frontend/admin/abuse_reports/components/abuse_report_row_spec.js
+++ b/spec/frontend/admin/abuse_reports/components/abuse_report_row_spec.js
@@ -94,4 +94,19 @@ describe('AbuseReportRow', () => {
it('renders abuse category', () => {
expect(findAbuseCategory().exists()).toBe(true);
});
+
+ describe('aggregated report', () => {
+ const mockAggregatedAbuseReport = mockAbuseReports[1];
+ const { reportedUser, category, count } = mockAggregatedAbuseReport;
+
+ beforeEach(() => {
+ createComponent({ report: mockAggregatedAbuseReport });
+ });
+
+ it('displays title with number of aggregated reports', () => {
+ expect(findAbuseReportTitle().text()).toMatchInterpolatedText(
+ `${reportedUser.name} reported for ${category} by ${count} users`,
+ );
+ });
+ });
});