# why
- act does not need to substitute variables on self-heal for
`dragAndDrop()`
- the only args `dragAndDrop()` needs are selectors
# what changed
- gated var substitution on method type
# test plan
- added tests to ensure variables do not get substituted on
`dragAndDrop()`
<!-- This is an auto-generated description by cubic. -->
---
## Summary by cubic
Fixes variable substitution in `act()` so drag-and-drop arguments keep
their literal selector values instead of being treated as text
templates.
- Skips `substituteVariablesInArguments` for `dragAndDrop` actions while
preserving it for other methods.
- Adds tests covering inferred, supplied, and self-heal drag actions
with variables present.
<sup>Written for commit 32e7744c7032ab539baddf01f014c56a5cd0ea98.
Summary will update on new commits.</sup>
<a
href="https://cubic.dev/pr/browserbase/stagehand/pull/3383?utm_source=github"
target="_blank" rel="noopener noreferrer"
data-no-image-dialog="true"><picture><source
media="(prefers-color-scheme: dark)"
srcset="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"><source
media="(prefers-color-scheme: light)"
srcset="https://www.cubic.dev/buttons/review-in-cubic-light.svg"><img
alt="View guided diff"
src="https://www.cubic.dev/buttons/review-in-cubic-light.svg"></picture></a>
<a
href="https://www.cubic.dev/action/auto-fix/pr/browserbase/stagehand/3383?returnTo=https%3A%2F%2Fgithub.com%2Fbrowserbase%2Fstagehand%2Fpull%2F3383&source=description"
target="_blank" rel="noopener noreferrer"
data-no-image-dialog="true"><picture><source
media="(prefers-color-scheme: dark)"
srcset="https://www.cubic.dev/buttons/turn-on-auto-fix-dark.svg"><source
media="(prefers-color-scheme: light)"
srcset="https://www.cubic.dev/buttons/turn-on-auto-fix-light.svg"><img
alt="Turn on auto-fix"
src="https://www.cubic.dev/buttons/turn-on-auto-fix-light.svg"></picture></a>
<!-- End of auto-generated description by cubic. -->