public void WhenSetMoreThenOnceThenDoesNotDuplicate()
		{
			var mapdoc = new HbmMapping();
			var rc = new SubclassMapper(typeof(InheritedSimple), mapdoc);
			rc.Synchronize("T1", "T2");
			rc.Synchronize("T3", "T2");
			mapdoc.SubClasses[0].Synchronize.Select(x => x.table).Should().Have.SameValuesAs("T1", "T2", "T3");
		}
		public void WhenSetMoreThenOnceThenDoesNotDuplicate()
		{
			var mapdoc = new HbmMapping();
			var rc = new SubclassMapper(typeof(InheritedSimple), mapdoc);
			rc.Synchronize("T1", "T2");
			rc.Synchronize("T3", "T2");
			Assert.That(mapdoc.SubClasses[0].Synchronize.Select(x => x.table), Is.EquivalentTo(new [] {"T1", "T2", "T3"}));
		}
        public void WhenSetMoreThenOnceThenDoesNotDuplicate()
        {
            var mapdoc = new HbmMapping();
            var rc     = new SubclassMapper(typeof(InheritedSimple), mapdoc);

            rc.Synchronize("T1", "T2");
            rc.Synchronize("T3", "T2");
            mapdoc.SubClasses[0].Synchronize.Select(x => x.table).Should().Have.SameValuesAs("T1", "T2", "T3");
        }
Exemple #4
0
        public void WhenSetMoreThenOnceThenDoesNotDuplicate()
        {
            var mapdoc = new HbmMapping();
            var rc     = new SubclassMapper(typeof(InheritedSimple), mapdoc);

            rc.Synchronize("T1", "T2");
            rc.Synchronize("T3", "T2");
            Assert.That(mapdoc.SubClasses[0].Synchronize.Select(x => x.table), Is.EquivalentTo(new [] { "T1", "T2", "T3" }));
        }
Exemple #5
0
        public void WhenSetSyncWithNullThenDoesNotThrows()
        {
            var mapdoc = new HbmMapping();
            var rc     = new SubclassMapper(typeof(InheritedSimple), mapdoc);

            Assert.That(() => rc.Synchronize(null), Throws.Nothing);
        }
		public void WhenSetSyncMixedWithNullAndEmptyThenAddOnlyValid()
		{
			var mapdoc = new HbmMapping();
			var rc = new SubclassMapper(typeof(InheritedSimple), mapdoc);
			rc.Synchronize("", "  ATable   ", "     ", null);
			mapdoc.SubClasses[0].Synchronize.Single().table.Should().Be("ATable");
		}
        public void WhenSetSyncMixedWithNullAndEmptyThenAddOnlyValid()
        {
            var mapdoc = new HbmMapping();
            var rc     = new SubclassMapper(typeof(InheritedSimple), mapdoc);

            rc.Synchronize("", "  ATable   ", "     ", null);
            mapdoc.SubClasses[0].Synchronize.Single().table.Should().Be("ATable");
        }
		public void WhenSetSyncWithNullThenDoesNotThrows()
		{
			var mapdoc = new HbmMapping();
			var rc = new SubclassMapper(typeof(InheritedSimple), mapdoc);
			Assert.That(() => rc.Synchronize(null), Throws.Nothing);
		}