Beispiel #1
0
 public void NameWithNullValue()
 {
     JsonMember member = new JsonMember("foo", null);
     Assert.AreEqual("foo", member.Name);
     Assert.IsNull(member.Value);
     Assert.AreEqual("foo: ", member.ToString());
 }
Beispiel #2
0
 public void NameWithNonNullValue()
 {
     JsonMember member = new JsonMember("foo", "bar");
     Assert.AreEqual("foo", member.Name);
     Assert.AreEqual("bar", member.Value);
     Assert.AreEqual("foo: bar", member.ToString());
 }
Beispiel #3
0
 public void Default()
 {
     JsonMember member = new JsonMember();
     Assert.AreEqual(string.Empty, member.Name);
     Assert.IsNull(member.Value);
     Assert.AreEqual(string.Empty, member.ToString());
 }
Beispiel #4
0
        public void NameWithNonNullValue()
        {
            JsonMember member = new JsonMember("foo", "bar");

            Assert.AreEqual("foo", member.Name);
            Assert.AreEqual("bar", member.Value);
            Assert.AreEqual("foo: bar", member.ToString());
        }
Beispiel #5
0
        public void NameWithNullValue()
        {
            JsonMember member = new JsonMember("foo", null);

            Assert.AreEqual("foo", member.Name);
            Assert.IsNull(member.Value);
            Assert.AreEqual("foo: ", member.ToString());
        }
Beispiel #6
0
        public void Default()
        {
            JsonMember member = new JsonMember();

            Assert.AreEqual(string.Empty, member.Name);
            Assert.IsNull(member.Value);
            Assert.AreEqual(string.Empty, member.ToString());
        }
        public void Default()
        {
            var member = new JsonMember();

            Assert.IsNull(member.Name);
            Assert.IsNull(member.Value);
            Assert.IsEmpty(member.ToString());
        }