private void ToString_Parameterized(double value, string expectedResult) { // Arrange var doubleNode = new JsonDoubleNode(value); // Act string result = doubleNode.ToString(); // Assert Assert.AreEqual(expectedResult, result); }
public void ToString_DecimalValue_DefaultCulture() { // Arrange var node = new JsonDoubleNode(0.1234567); // Act string json = node.ToString(); // Assert Assert.IsNotNull(node); Assert.AreEqual("0.1234567", json); }
public void ToString_DecimalValue_CultureWithDifferentDecimalSeparator() { CultureTestUtility.ExecuteInCulture("fr-FR", () => { // Arrange var node = new JsonDoubleNode(0.1234567); // Act string json = node.ToString(); // Assert Assert.IsNotNull(node); Assert.AreEqual("0.1234567", json); }); }