public void WhenRegisterJoinedSubclassWithNoRootThenCanAskForIsEntity()
		{
			var inspector = new ExplicitlyDeclaredModel();
			inspector.AddAsTablePerClassEntity(typeof(Inherited1));

			inspector.IsEntity(typeof(Inherited1)).Should().Be.True();
		}
		public void WhenRegisteredAsJoinedSubclassThenIsEntity()
		{
			var inspector = new ExplicitlyDeclaredModel();
			inspector.AddAsRootEntity(typeof(MyClass));
			inspector.AddAsTablePerClassEntity(typeof(Inherited1));

			inspector.IsEntity(typeof(Inherited1)).Should().Be.True();
		}
		public void WhenRegisteredAsSubclassThenIsEntity()
		{
			var inspector = new ExplicitlyDeclaredModel();
			inspector.AddAsRootEntity(typeof(MyClass));
			inspector.AddAsTablePerClassHierarchyEntity(typeof(Inherited1));

			Assert.That(inspector.IsEntity(typeof(Inherited1)), Is.True);
		}
		public void WhenRegisteredAsRootThenIsEntity()
		{
			var inspector = new ExplicitlyDeclaredModel();
			inspector.AddAsRootEntity(typeof(MyClass));

			inspector.IsEntity(typeof(MyClass)).Should().Be.True();
		}
		public void WhenRegisteredAsRootThenIsEntity()
		{
			var inspector = new ExplicitlyDeclaredModel();
			inspector.AddAsRootEntity(typeof(MyClass));

			Assert.That(inspector.IsEntity(typeof(MyClass)), Is.True);
		}
Esempio n. 6
0
        bool IModelInspector.IsEntity(System.Type type)
        {
            bool declaredResult = declaredModel.IsEntity(type);

            return(isEntity(type, declaredResult));
        }