Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove duplicate tests and filters #33

Merged

Conversation

felixfontein
Copy link
Collaborator

Fixes the ansible-core sanity test errors in ansible/ansible#78674 (comment).

@briantist
Copy link
Contributor

This looks good to me, but what are aliases exactly? Are they just when filters/tests of different names use the same implementation? In the code comment, it looks for identical docs, which makes me wonder, how do we determine which is the "canonical" page?

@felixfontein
Copy link
Collaborator Author

This looks good to me, but what are aliases exactly? Are they just when filters/tests of different names use the same implementation?

Basically yes. (In ansible-core, symlinks are used to implement this for the documentation, and in the code the same function is exposed with different names.)

In the code comment, it looks for identical docs, which makes me wonder, how do we determine which is the "canonical" page?

Assuming that symlinks are used for the .yml files, the canonical version is the one whose name: coincides with the plugin's name. For example, in ansible-core's repo, lib/ansible/plugins/test/abs.yml has name: abs, and lib/ansible/plugins/test/is_abs.yml (symlink) also has name: abs.

@felixfontein felixfontein merged commit ce5f4c8 into ansible-community:main Sep 14, 2022
@felixfontein felixfontein deleted the fix-duplicate-tests-filters branch September 14, 2022 11:59
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.

2 participants