Ejemplo n.º 1
0
        public void TestExtensions()
        {
            //this is not correct
            var s = "String_Test";

            s.GetSCType().HasValue.Should().BeFalse();

            //test is of type
            SC_String obj = new SC_String("lol");

            obj.IsOfType <SC_String>().Should().BeTrue();
            obj.IsOfType <SC_Int, SC_String>().Should().BeTrue();
        }
Ejemplo n.º 2
0
        public void TestSCStuff()
        {
            SC_String s = new SC_String();

            s.value.Should().Be("");

            s.GetValueAsStringWithPrefix().Should().Be("Str_");

            s.ToString().Should().Be("Str_");

            SC_Int innt = new SC_Int("1");

            innt.GetValueAs <int>().Should().Be(1);
            innt.ToString().Should().Be("Int_1");

            SC_Long lon = new SC_Long(1);

            lon.ToString().Should().Be("Lon_1");
        }