Exemplo n.º 1
0
        public void Nameはコンストラクタで指定された列名を返す()
        {
            // when
            Column column = new Column("test1", null, null);

            // then
            Assert.AreEqual("test1", column.Name);
        }
Exemplo n.º 2
0
        public void ToStringは列タイプも列要素タイプも指定されていない場合には列名を表す文字列を返す()
        {
            // when
            Column column = new Column("x", null, null);

            // then
            Assert.AreEqual("x", column.ToString());
        }
Exemplo n.º 3
0
        public void ComponentTypeはコンストラクタで指定された列要素タイプを返す()
        {
            // when
            Column column = new Column(null, null, "ctype1");

            // then
            Assert.AreEqual("ctype1", column.ComponentType);
        }
Exemplo n.º 4
0
        public void ToStringは列名と列タイプのみが指定されている場合には列名コロン列タイプ型式の文字列を返す()
        {
            // when
            Column column = new Column("x", "t", null);

            // then
            Assert.AreEqual("x:t", column.ToString());
        }
Exemplo n.º 5
0
        public void ToStringは列名と列タイプと列要素タイプが指定されている場合には列名コロン列タイプ小なり列要素タイプ大なり型式の文字列を返す()
        {
            // when
            Column column = new Column("x", "t", "ct");

            // then
            Assert.AreEqual("x:t<ct>", column.ToString());
        }
Exemplo n.º 6
0
        private void SetTypeはColumnの型を指定できる(Type type, string typeText, string componentType)
        {
            // setup
            Column column = new Column("x", null, null);

            // when
            column.SetType(type);

            // then
            Console.WriteLine(column);
            Assert.AreEqual(typeText, column.Type);
            Assert.AreEqual(componentType, column.ComponentType);
        }
Exemplo n.º 7
0
        private void IsArrayは列タイプがnullで列要素タイプがnullでない場合にtrueを返す(string type, string ctype, bool expected)
        {
            // when
            Column column = new Column(null, type, ctype);

            // then
            Assert.AreEqual(expected, column.IsArray());
        }
Exemplo n.º 8
0
        public void Typeはコンストラクタで指定された列タイプを返す()
        {
            // when
            Column column = new Column(null, "type1", null);

            // then
            Assert.AreEqual("type1", column.Type);
        }
Exemplo n.º 9
0
        public void ToStringは列名と列要素タイプのみが指定されている場合には列名コロン列要素タイプ大カッコ型式の文字列を返す()
        {
            // when
            Column column = new Column("x", null, "ct");

            // then
            Assert.AreEqual("x:ct[]", column.ToString());
        }