Skip to content
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

[HTML] don't indent after DOCTYPE, add indentation tests #2473

Merged

Conversation

keith-hall
Copy link
Collaborator

@keith-hall keith-hall commented Sep 1, 2020

This PR adds some basic indentation tests for the HTML package, and prevents unexpected indentation from occurring after a doctype directive. This follows the PHP one, whereby we are only using the test file to make assertions about indentation, not scopes, to keep things simple. (IMO, it would be a fairly invasive style change to rework the existing syntax tests to also assert indentation doesn't change, so a separate test file keeps it neat and tidy.)

EDIT: note that due to the presence of multi-line comments in the test file, we can only assert reindent-unchanged and not reindent-unindented due to the default preserveIndent behavior as mentioned at sublimehq/sublime_text#1271 (comment)

@wbond wbond merged commit 1b3837f into sublimehq:master Sep 15, 2020
@wbond
Copy link
Member

wbond commented Sep 15, 2020

Thanks!

mitranim pushed a commit to mitranim/Packages that referenced this pull request Mar 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants