Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Add formatter for the charset .editorconfig option - #330

#330
Merged
JoeRobich merged 1 commit into
dotnet:masterdotnet/format:masterfrom
JoeRobich:add-charset-formatterJoeRobich/format:add-charset-formatterCopy head branch name to clipboard
Aug 15, 2019
Merged

Add formatter for the charset .editorconfig option#330
JoeRobich merged 1 commit into
dotnet:masterdotnet/format:masterfrom
JoeRobich:add-charset-formatterJoeRobich/format:add-charset-formatterCopy head branch name to clipboard

Conversation

@JoeRobich

Copy link
Copy Markdown
Member

charset support was requested by the community and should wrap up our support for the the core .editorconfig options.

@RikkiGibson
RikkiGibson self-requested a review August 13, 2019 05:42
Comment thread src/Formatters/CharsetFormatter.cs Outdated
Comment thread tests/Formatters/AbstractFormatterTests.cs Outdated
var codeEncoding = CharsetFormatter.GetCharset(codeValue);
var expectedEncoding = CharsetFormatter.GetCharset(expectedValue);

var testCode = "class C { }";

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be worthwhile to verify that the encoding really changed the test code contents, perhaps by making the test class name a more complex character, and including a byte[] with the final raw content in the InlineData

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, we will need to make an integration test for that. There wouldn't be any change until the workspace has saved the document changes. Since these tests use AdhocWorkspace that isn't possible because it doesn't implement persistence.

@JoeRobich
JoeRobich force-pushed the add-charset-formatter branch from 1e95981 to 87b050c Compare August 14, 2019 16:25
@JoeRobich
JoeRobich merged commit 0a22d16 into dotnet:master Aug 15, 2019
@JoeRobich
JoeRobich deleted the add-charset-formatter branch March 5, 2021 21:01
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

Morty Proxy This is a proxified and sanitized view of the page, visit original site.