public void ConstructorWith3Parameter()
        {
            var item = new CrossRefFieldAttribute("RefFieldName", "referenceTableName", false);

            Assert.AreEqual("RefFieldName", item.RefFieldName);
            Assert.AreEqual("referenceTableName", item.ReferenceTableName);
            Assert.AreEqual(false, item.AllowMultiple);
        }
        public void ConstructorWith4Parameter()
        {
            var item = new CrossRefFieldAttribute("Test_RefFieldName", "Test_referenceTableName", true, "Test_displayFieldList");

            Assert.AreEqual("Test_RefFieldName", item.RefFieldName);
            Assert.AreEqual("Test_referenceTableName", item.ReferenceTableName);
            Assert.AreEqual(true, item.AllowMultiple);
            Assert.AreEqual("Test_displayFieldList", item.DisplayFieldList);
        }
Ejemplo n.º 3
0
 /// <summary>
 /// Creates the column.
 /// </summary>
 /// <param name="owner">The owner.</param>
 /// <param name="columns">The columns.</param>
 /// <param name="crossRef">The cross reference.</param>
 /// <returns>ColumnItem.</returns>
 public static ColumnItem CreateColumn(IRefreashable owner, ColumnCollection columns, CrossRefFieldAttribute crossRef = null)
 {
     return crossRef != null ? new CrossRefColumnItem(owner, columns) : new ColumnItem(owner, columns);
 }
        public void ConstructorWith1Parameter()
        {
            var item = new CrossRefFieldAttribute("test_string");

            Assert.AreEqual("test_string", item.RefFieldName);
        }