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

Fix test name to include specification & feature name #95

Merged
merged 1 commit into from
Dec 10, 2024

Conversation

jdaugherty
Copy link
Contributor

I was only putting the method name in the saved file name, now the file will have the full path.

Here's an example after this change:
image

Before it would have been PASSED-should_be_able_to_use_download_methods-20241209-140435.mp4

@jdaugherty jdaugherty requested a review from matrei December 9, 2024 19:06
Copy link
Contributor

@matrei matrei left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion for code formatting and logic:

    ContainerGebTestDescription(IterationInfo testInfo) {
        testId = [
                testInfo.feature.spec.displayName,
                testInfo.feature.displayName,
                testInfo.displayName != testInfo.feature.displayName ? testInfo.displayName : null,
                testInfo.displayName != testInfo.feature.displayName ? testInfo.iterationIndex : null
        ].findAll(/* Remove nulls */).join(' ')

        String safeName = testId.replaceAll('\\W+', '_')
        filesystemFriendlyName = safeName
    }

@jdaugherty jdaugherty merged commit d268584 into grails:5.0.x Dec 10, 2024
5 checks passed
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