-
Notifications
You must be signed in to change notification settings - Fork 43
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
Detect deployments that can not impact test classes and run only specified tests in that case to improve performances #444
Comments
Just wanted to point, that the notion of "metadata that cannot break anything for sure", is a bit loose considering the edge cases when a Static Resource, Reports or Custom Labels translation could be referenced somewhere in code. Nevertheless, we can maybe achieve such a list if we make sure that there are some strong commandments of not allowing any references anywhere in our code of such metadata types. Then this sanity list could potentially be of some more effective use. I guess, we're still in a safe spot to say that certain metadata like CSS classes on LWC, or page layouts(hopefully phased out completely by the Dyn Forms), should under any circumstance cause any coded logic to break, thus unnecessary to be validated by a comprehensive Apex Test suite. |
@EndritSino maybe we can accept to take the risk for some of them, because negative impact would be only in case of dynamic reference (static references will be catched by deployment simulation with a compile error) Initial list from Macej Ptak
|
Dev ready in future v5 :) Only remaining item is a bug in SF cli -> forcedotcom/cli#3023 @EndritSino @0ptaq0 any feedback about the list ? :) Smart Deployments TestsNot all metadata updates can break test classes, use Smart Deployment Tests to skip running test classes if ALL the following conditions are met:
Activate Smart Deployment tests with:
Defaut list for NOT_IMPACTING_METADATA_TYPES (can be overriden with comma-separated list on env var NOT_IMPACTING_METADATA_TYPES)
Note: if you want to disable Smart test classes for a PR, add nosmart in the text of the latest commit. |
Solved in latest alpha, ready to be tested :) |
detecting which type of metadata update can not break anything for sure, and if only those metadata are updated in a deployment, dynamically call just a subset of specified tests (that would be always the same list defined by the release manager)
Except for production deployments when we keep RunLocalTests
Cc @pablogonzaleznetwork
The text was updated successfully, but these errors were encountered: