interpolation-check
What it does
Section titled “What it does”Reports a single-quoted string that holds #{...}.
Why it matters
Section titled “Why it matters”Single quotes do not interpolate, so the text #{b} stays as it is. It is a typical slip when quotes are changed.
To fix, use double quotes, or remove the #{...}.
Example
Section titled “Example”...y = :okz = 'a #{b}'.../(?<a>x)(?:y)/...Configuration
Section titled “Configuration”ruby: lint: rules: interpolation-check: warn # off, warn (default), errorEnabled by the presets: ruby/rubocop.
Suppress one line with sudsy-disable-next-line interpolation-check in a comment of the file’s language.
Upstream equivalents
Section titled “Upstream equivalents”The same check in other tools; Sudsy reports what each upstream rule reports.
| Tool | Rule | Match |
|---|---|---|
| rubocop | Lint/InterpolationCheck |
full |