public void Test8() { var dataSet = new CremaDataSet(); var dataType = dataSet.Types.Add(); var dataTable = dataSet.AddRandomTable(); var derivedTable = dataSet.AddDerivedTable(); var columnCount1 = dataTable.Columns.Count; var template = new CremaTemplate(dataTable); var columnCount2 = template.Columns.Count; var column = template.Columns.RandomOrDefault(item => item.IsKey == false && item.Unique == false); if (column == null) { return; } column.Delete(); template.AcceptChanges(); Assert.AreEqual(columnCount1 - 1, template.Columns.Count); Assert.AreEqual(columnCount1 - 1, dataTable.Columns.Count); Assert.AreEqual(columnCount1 - 1, derivedTable.Columns.Count); }