Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Smarter copying of the rest specs and tests #52114
Smarter copying of the rest specs and tests #52114
Changes from all commits
c7d36e0
1e02fbe
02f95b8
7b81e65
f334d40
c1ee4ff
f43429c
818e761
bddf05b
0c1d164
bbcde3a
2dc1a3a
8942ac2
2f5739c
907c0dd
173b494
6d0aec5
6a74f0b
a391dd7
9583d15
1617f6f
d86fc58
852b30e
10700bc
bb84161
2e4d1d6
9e6e2aa
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should live in the plugin not in the task.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, thinking about this a bit more, I think this needs to stay in the task for a couple reasons:
This method checks against the source dir for tests committed to GH, but also checks the output directory for tests copied over by prior gradle tasks. This is why the spec task depends on the test task. Since this evaluation is done in the task at execution time, I believe this is a reliable way to ensure that any source or copied tests exist.
We can not actually skip the creation of the task based on the output of this. The spec copy task needs to execute if the project has no rest tests, but also you requested to include some tests, and the IIUC the extension property isn't guaranteed to be resolved at configuration time. e.g. since we can not read the property at configuration time we will always need to create the task in case there are no tests at all, but you need the spec (docs and HLRC are examples of this).