Handle skipped tests in "Not run" column - #3743
Conversation
williamjallen
left a comment
There was a problem hiding this comment.
I'm conflicted on whether this belongs in CDash, or whether this should be added as a CTest property. I'm leaning towards the latter because it's possible that some projects will want to dynamically set the list of not run test warnings. The build error filter feature removed in #3650 had roughly the same considerations. Any thoughts on this?
|
It could be in addition to having a "Skipped" test property in CTest. However in CDash we would need a way to handle the display of skipped tests. Where you thinking something else? |
|
@jjomier Is your goal just to differentiate between disabled tests and tests which were "not run" for a different reason? We want to minimize the number of configuration options if possible, so I'm hesitant to approve this as-is. After discussing this internally, we think the best approach is to just match the text "Disabled" in the details field without it being user-configurable. Thoughts? |
|
@williamjallen yes the idea is to not pollute the tests that are marked as not run when we look at the dashboard. I like the idea of matching "Disabled". |
This commit introduces a new `notRunSkippedDetailsRegex` property to the Project model, allowing users to define regex patterns for not-run test details. A corresponding validation rule is added to ensure the regex is valid. The Build model now includes a method to count not-run tests that do not match the specified patterns, and the GraphQL schema is updated to expose this functionality. Additionally, UI components are modified to display the warning count and adjust test status colors based on the new regex patterns. Tests are also added to verify the new functionality.
This commit removes the `notRunSkippedDetailsRegex` property from the Project model and associated validation rule, simplifying the logic for handling not-run tests. The `notRunTestsWarningCount` method in the Build model is updated to exclude tests with details marked as "Disabled". The GraphQL schema and UI components are adjusted accordingly to reflect these changes. Additionally, tests are updated to ensure correct behavior without the regex pattern handling.
ef9cd03 to
fc65763
Compare
This commit improves the formatting of the `testStatusToColorClass` and `testStatusToTextColorClass` functions in the TestDisplay component. The switch cases have been reformatted for better readability, maintaining the same functionality. No changes to logic or behavior were made.
This commit simplifies the `notRunTestsWarningCount` method in the Build model by using a more efficient query to count not-run tests that do not have details marked as "Disabled". Additionally, the API response in the Index controller is updated to reflect the new method signature. Unused test methods in the TestDisplayTest class have been removed to clean up the codebase.
This commit introduces a new
notRunSkippedDetailsRegexproperty to the Project model, allowing users to define regex patterns for not-run test details. A corresponding validation rule is added to ensure the regex is valid. The Build model now includes a method to count not-run tests that do not match the specified patterns, and the GraphQL schema is updated to expose this functionality. Additionally, UI components are modified to display the warning count and adjust test status colors based on the new regex patterns. Tests are also added to verify the new functionality.