示例#1
0
        public void IsInstanceOfType_Null_Throws()
        {
            // arrange
            var type = new IdType();

            // act
            // assert
            Assert.Throws <ArgumentNullException>(
                () => type.IsInstanceOfType(null));
        }
示例#2
0
        public void IsInstanceOfType_Wrong_ValueNode()
        {
            // arrange
            var type  = new IdType();
            var input = new FloatValueNode("123456");

            // act
            bool result = type.IsInstanceOfType(input);

            // assert
            Assert.False(result);
        }
示例#3
0
        public void IsInstanceOfType_NullValueNode()
        {
            // arrange
            var           type  = new IdType();
            NullValueNode input = NullValueNode.Default;

            // act
            bool result = type.IsInstanceOfType(input);

            // assert
            Assert.True(result);
        }
示例#4
0
        public void IsInstanceOfType_IntValueNode()
        {
            // arrange
            var type  = new IdType();
            var input = new IntValueNode("123456");

            // act
            bool result = type.IsInstanceOfType(input);

            // assert
            Assert.True(result);
        }