mirror of
https://github.com/kubescape/kubescape.git
synced 2026-03-04 02:30:29 +00:00
Pull Request Description: Changes Made Added a new test case TestParseSetArgs_InvalidKey in the config package to cover scenarios where an invalid key is provided in the set command arguments. Test Case Details Function Tested: TestParseSetArgs_InvalidKey Test Objective: Ensures that the parseSetArgs function correctly handles the scenario where an invalid key is provided, returning an appropriate error message. Test Input: Command arguments with an invalid key, e.g., invalidKey=value1. Expected Output: The function should return an error message indicating that the provided key is unknown, along with the list of supported keys. Motivation This new test case enhances the test coverage for the parseSetArgs function, ensuring robust handling of invalid keys during the configuration setting process. By validating that the function produces the expected error message for such cases, we contribute to the overall reliability of the codebase. This addition further strengthens the testing suite for the config package, promoting code quality and correctness. Signed-off-by: Umair <58398786+Umair0343@users.noreply.github.com>