Skip to content

test(plugins): report nested metadata paths in validation errors #2164 - #2480

Open
Rakshak05 wants to merge 2 commits into
utksh1:mainfrom
Rakshak05:issue-#2164
Open

test(plugins): report nested metadata paths in validation errors #2164#2480
Rakshak05 wants to merge 2 commits into
utksh1:mainfrom
Rakshak05:issue-#2164

Conversation

@Rakshak05

Copy link
Copy Markdown
Contributor

Description

This PR fixes issue #2164 by adding focused metadata fixtures and unit tests for plugin validation errors within nested objects and lists. It enhances PluginMetadataValidator to ensure precise JSON path reporting for nested structures and array elements, including:

  • Option element indexes for select and multiselect fields (fields[{i}].options[{j}])
  • Mutually exclusive validation rule element indexes (validation.{key}.mutually_exclusive[{j}])
  • Python package dependency array element indexes (dependencies.python_packages[{i}])

Related Issues

Closes #2164

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update

How Has This Been Tested?

Executed the unit test suite locally:

python -m pytest testing/backend/unit/test_plugin_validator.py -v

All 101 unit tests (including 11 new tests in TestNestedObjectValidationPaths) passed cleanly.

Checklist

  • My code follows the code style of this project.
  • I have performed a self-review of my own code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have made corresponding changes to the documentation.
  • My changes generate no new warnings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

test(plugins): report nested metadata paths in validation errors

1 participant