From 667114d46dfdcb31a122b6ebe7eba65833e5fb32 Mon Sep 17 00:00:00 2001 From: Papa Bakary Camara Date: Thu, 13 Jan 2022 08:57:00 +0100 Subject: [PATCH] Add test data for organisation-wide disabled rules --- testdata/testdata.go | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/testdata/testdata.go b/testdata/testdata.go index 685096b3f..1a2b011d7 100644 --- a/testdata/testdata.go +++ b/testdata/testdata.go @@ -1049,6 +1049,44 @@ var ( "Eight", "Nine", } + ResponseNoRulesDisabledSystemWide = `{ + "meta": { + "count": 0 + }, + "data": [] + }` + + ResponseRule1DisabledSystemWide = struct { + Status string `json:"status"` + RuleDisable []types.SystemWideRuleDisable `json:"disabledRules"` + }{ + Status: "ok", + RuleDisable: []types.SystemWideRuleDisable{ + { + OrgID: OrgID, + UserID: UserID, + RuleID: Rule1ID, + ErrorKey: ErrorKey1, + Justification: "Rule 1 disabled for testing purposes", + }, + }, + } + + ResponseRule2DisabledSystemWide = struct { + Status string `json:"status"` + RuleDisable []types.SystemWideRuleDisable `json:"disabledRules"` + }{ + Status: "ok", + RuleDisable: []types.SystemWideRuleDisable{ + { + OrgID: OrgID, + UserID: UserID, + RuleID: Rule2ID, + ErrorKey: ErrorKey2, + Justification: "Rule 2 disabled for testing purposes", + }, + }, + } ) func timeToStr(t time.Time) string {