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

Filter backticks in TestItem IDs #1211

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

plemarquand
Copy link
Contributor

Test functions with backticks in their identifier should have them filtered out.

This is a stopgap until apple/swift-syntax#2576 is ready.

Test functions with backticks in their identifier should have them
filtered out.

This is a stopgap until apple/swift-syntax#2576 is ready.
@plemarquand
Copy link
Contributor Author

@swift-ci Please test

Comment on lines +72 to +73
self.id = id.filter { $0 != "`" }
self.label = id == label ? self.id : label
Copy link
Collaborator

Choose a reason for hiding this comment

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

I would prefer to only do the filtering on the function name. Once we start including the file’s name in the ID (#1152), we shouldn’t remove the backtick from eg. the filename.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@grynspan Can you specify running a swift-testing test via --filter with an ID that has the file's name + line + column in the ID, a la #1152?

My main requirement for these IDs is that I can take the IDs that sourcekit-lsp and pass them directly to swift-testing without converting them in any way.

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.

None yet

2 participants