diff --git a/packages/salesforcedx-vscode-core/package.json b/packages/salesforcedx-vscode-core/package.json index a8a56554dd3..bf76380d25c 100644 --- a/packages/salesforcedx-vscode-core/package.json +++ b/packages/salesforcedx-vscode-core/package.json @@ -307,7 +307,7 @@ }, { "command": "sfdx.lightning.rename", - "when": "sfdx:project_opened && resource =~ /.*/(lwc|aura)/[^/]+(/[^/]+\\.(html|css|js|xml|svg|cmp|app|design|auradoc))?$/" + "when": "sfdx:project_opened && resource =~ /.*/(lwc|aura)/[^/]+(/([^/]+\\.(html|css|js|xml|svg|cmp|app|design|auradoc)|__tests__))?(/[^/]+\\.js)?$/" } ], "commandPalette": [