You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Test]
public void Test_Unicode_CandidateNames()
{
var candidateName = new Language("Raúl", "en");
var candidate = new Candidate(
"candidate-1",
new InternationalizedText(new[] { candidateName }),
string.Empty,
string.Empty,
false);
List<Candidate> candidates = new List<Candidate>
{
candidate
};
var result = new Manifest(
"test-manifest",
ElectionType.general,
DateTime.Now,
DateTime.Now,
new GeopoliticalUnit[] { },
new Party[] { },
candidates.ToArray(),
new ContestDescription[] { },
new BallotStyle[] { },
new InternationalizedText(new Language[] { }),
new ContactInformation("na"));
var json = result.ToJson();
Assert.IsTrue(json.Contains("\"value\":\"Ra\\u00fal\""));
}
Environment
- OS:
Anything else?
No response
The text was updated successfully, but these errors were encountered:
Is there an existing issue for this?
Current Behavior
.ToJson() converts
ú
to\\u00f
Expected Behavior
.ToJson() should convert
ú
to\u00f
Steps To Reproduce
The following test should pass:
Environment
- OS:
Anything else?
No response
The text was updated successfully, but these errors were encountered: