kibana/x-pack/test/alerting_api_integration/security_and_spaces
Christos Nasikas 9a3fc89629
[ResponseOps][Rules] Validate timezone in rule routes (#201508)
## Summary

This PR adds validation only for internal routes that use the `rRule`
schema.

## Testing

1. Create a rule in main.
2. Snooze the rule by using the API as

```
POST /internal/alerting/rule/<ruleId>/_snooze
{
    "snooze_schedule": {
        "id": "e58e2340-dba6-454c-8308-b2ca66a7cf7b",
        "duration": 86400000,
        "rRule": {
            "dtstart": "2024-09-04T09:27:37.011Z",
            "tzid": "invalid",
            "freq": 2,
            "interval": 1,
            "byweekday": [
                "invalid"
            ]
        }
    }
}
```

4. Go to the rules page and verify that the rules are not loaded.
5. Switch to my PR.
6. Go to the rules page and verify that the rules load.

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-01-24 18:46:24 +01:00
..
group1 Revert "[ES body removal] @elastic/response-ops (#204882)" (#207899) 2025-01-22 22:47:06 -06:00
group2 [ResponseOps] Granular connector RBAC followup (#205818) 2025-01-21 13:33:54 -08:00
group3 [ResponseOps][Rules] Validate timezone in rule routes (#201508) 2025-01-24 18:46:24 +01:00
group4 Revert "[ES body removal] @elastic/response-ops (#204882)" (#207899) 2025-01-22 22:47:06 -06:00
group5 [ResponseOps] Granular Connector RBAC (#203503) 2025-01-06 10:53:35 -08:00
scenarios.ts [ResponseOps][Alerting] Decouple feature IDs from consumers (#183756) 2024-12-03 12:21:53 +02:00
setup.ts [Archive Migration] batch 2 of removing es_archives/empty_kibana (#138208) 2022-08-23 12:31:39 -07:00