In this commit, we refactor `FederatedResourceQuota` webhook
mainly matching on substrings instead of whole strings for reliability
and resilience and reformat the test case names to follow format
`Function_Scenario_ExpectedResult` for better readability.
Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
In this commit, we add unit tests for the `FederatedResourceQuota`
validation logic and its related components. The tests ensure that
the validation logic correctly handles various scenarios, including:
- Validating `FederatedResourceQuota` specifications with appropriate resource assignments.
- Detecting cases where overall resource limits are less than the assigned resources.
- Handling scenarios where resource names in assignments do not exist in the overall resources.
- Validating `FederatedResourceQuotaStatus` to ensure standard resource types and correct cluster names.
- Handling invalid resource lists in both `Overall` and `AggregatedStatus`.
Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>