fix(h026): fixes rule H026 for cases where id/class are part of another string

closes #281
This commit is contained in:
Christopher Pickering 2022-07-06 12:50:15 -05:00
parent a9b2b1cf86
commit 611b1fa57a
No known key found for this signature in database
GPG key ID: E14DB3B0A0FACF84

View file

@ -549,6 +549,10 @@ def test_H026(runner: CliRunner, tmp_file: TextIO) -> None:
assert result.exit_code == 0
assert "H026" not in result.output
write_to_file(tmp_file.name, b"<div x-id-y><div id-y><div x-id>")
result = runner.invoke(djlint, [tmp_file.name])
assert "H026" not in result.output
def test_T027(runner: CliRunner, tmp_file: TextIO) -> None:
write_to_file(tmp_file.name, b"{% blah 'asdf %}")