Skip to content

Commit 8551d9c

Browse files
committed
Disable formatting for test string
1 parent a2475a9 commit 8551d9c

File tree

1 file changed

+18
-11
lines changed

1 file changed

+18
-11
lines changed

Tests/SimpleConfigTest.cs

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -189,18 +189,25 @@ public void SetValueOverload()
189189
[Test]
190190
public void SaveAndLoadComments()
191191
{
192+
// clang-format off
192193
var cfgStr =
193-
"# Line1" + Environment.NewLine + "; Line2" + Environment.NewLine + "#" + Environment.NewLine +
194-
"# Line4" + Environment.NewLine + "[Section] # InlineComment1" + Environment.NewLine +
195-
"Setting = Value ; InlineComment2" + Environment.NewLine + Environment.NewLine + "# Line1 " +
196-
Environment.NewLine + "#Line2 " + Environment.NewLine + "## ###" + Environment.NewLine + ";Line4" +
197-
Environment.NewLine + "[Section2]" + Environment.NewLine + "Setting=\"Val;#ue\"# InlineComment3" +
198-
Environment.NewLine +
199-
"ValidUglySetting1 = \"this is # not a comment\" # this is a comment \"with a quote\" inside" +
200-
Environment.NewLine + "ValidUglySetting2 = this is \\# not a comment # this is a comment" +
201-
Environment.NewLine +
202-
("ValidUglySetting3 = { first, \"second # still, second\" } # comment \"with a quote\" and a " +
203-
"closing brace }");
194+
"# Line1" + Environment.NewLine +
195+
"; Line2" + Environment.NewLine +
196+
"#" + Environment.NewLine +
197+
"# Line4" + Environment.NewLine +
198+
"[Section] # InlineComment1" + Environment.NewLine +
199+
"Setting = Value ; InlineComment2" + Environment.NewLine +
200+
Environment.NewLine +
201+
"# Line1 " + Environment.NewLine +
202+
"#Line2 " + Environment.NewLine +
203+
"## ###" + Environment.NewLine +
204+
";Line4" + Environment.NewLine +
205+
"[Section2]" + Environment.NewLine +
206+
"Setting=\"Val;#ue\"# InlineComment3" + Environment.NewLine +
207+
"ValidUglySetting1 = \"this is # not a comment\" # this is a comment \"with a quote\" inside" + Environment.NewLine +
208+
"ValidUglySetting2 = this is \\# not a comment # this is a comment" + Environment.NewLine +
209+
"ValidUglySetting3 = { first, \"second # still, second\" } # comment \"with a quote\" and a closing brace }";
210+
// clang-format on
204211

205212
var cfg = Configuration.LoadFromString(cfgStr);
206213

0 commit comments

Comments
 (0)