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

Improve remove_duplicate_tests.py #395

Open
4 tasks
llxia opened this issue Jan 26, 2023 · 5 comments
Open
4 tasks

Improve remove_duplicate_tests.py #395

llxia opened this issue Jan 26, 2023 · 5 comments
Labels
enhancement New feature or request

Comments

@llxia
Copy link
Contributor

llxia commented Jan 26, 2023

With #393, we have remove_duplicate_tests.py to remove duplicate tests. However, there are some enhancements that we can make:

  • find a way to persevere comments (whether the license or actual comments within the root element). For example https://stackoverflow.com/questions/33573807/faithfully-preserve-comments-in-parsed-xml. The license can be different from repo to repo. Users should not need to provide --license-file. Also, actual comments in the playlist.xml should be preserved.
  • We should compare the content instead of simply removing elements with the duplicated <testCaseName>. Only remove it if everything under <test> is the same. Otherwise, we should print a warning message (i.e., warning: found duplicated testCaseName xxx, but the content is not identical.)
  • Update remove_duplicate_tests.py to take a git repo. remove_duplicate_tests.py should git clone the repo and check all subdirectories to find playlist.xml and remove duplicate tests if possible.
  • create a GitHub workflow for this task. On a schedule (i.e., biweekly), run remove_duplicate_tests.py against all repos and create auto PR against specific repo if needed.
    https://github.com/adoptium/aqa-tests
    https://github.com/eclipse-openj9/openj9
    https://github.com/adoptium/temurin-build
@llxia llxia added the enhancement New feature or request label Jan 26, 2023
@ArkaprabhaChakraborty
Copy link
Contributor

Hi, can I get this assigned?

@ArkaprabhaChakraborty
Copy link
Contributor

PS we might have to make several PRs to this completely issue ina good trackable way :)

@llxia
Copy link
Contributor Author

llxia commented Mar 1, 2023

@ArkaprabhaChakraborty yes, that is correct. This is a top-level issue to track the enhancements. Please divide the deliverables into PRs that are of a reasonable size and contain specific features. Thanks

@ArkaprabhaChakraborty
Copy link
Contributor

ArkaprabhaChakraborty commented Mar 10, 2023

Where can I add tests for the script? :) More of like unit tests you can say :)

@ArkaprabhaChakraborty
Copy link
Contributor

Okay, I tried different ways to parse comments outside the "tree" but none worked with python's default XMLParser... StackOverflow discussion

A seemingly simple problem just got weirder :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Todo
Development

No branches or pull requests

2 participants