-
Notifications
You must be signed in to change notification settings - Fork 29k
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
Test: editor.codeActionsOnSave #48303
Comments
@mjbvz sorry, but I have no clue what you are talking about under "Other settings" and what is the "unicorn" thing? |
If I understand correctly, properties are scoped. It means
|
Yes, sorry about the confusion. The intent of that test is that no code actions of kind Let's say an extension returns three code actions with kinds:
With With With And with |
@sandy081 @mjbvz thanks for the clarification. A simple sentence in the "Background" section like "properties under editor.codeActionsOnSave are similar to glob patterns" would have made things clearer. Is this a new wildcard scheme in settings or are we using this scheme already somewhere? |
Complexity: 2
Test for #42092 and #46678
Background
The new
editor.codeActionsOnSave
setting lets you configure a set of source code actions to be run when you save file. For example, the setting:enables organize imports on save.
Testing
Basic
In a ts project, set:
In a ts file with un-ordered imports, save
Now make the file unformatted as well and save again
Disable
Now set
Confirm that organize imports is no longer run
Other settings
Try other forms such as
Confirm that only examples like 2 actually enable this setting. The specific rule is: apply all code actions whose kind (
source.organizeImports
) is equal to or a subpart of the setting kind (source
orsource.organizeImports
).Language specific overrides
Now try using this as a language specific setting:
Confirm that you can enable this setting for just ts and not for js
Confirm that the language specific setting overrides a global seting
Confirm that for settings such as:
That the settings are properly merged and organize imports is run
Timeouts
src/
before the ts server has fully loadedThe text was updated successfully, but these errors were encountered: