public void GetNavigationNodeCreatesCollectionNavigationNodeForManyMultiplicityProperty() { IEdmNavigationProperty property = HardCodedTestModel.GetDogMyPeopleNavProp(); SingleEntityNode parent = new SingleEntityCastNode(null, HardCodedTestModel.GetDogType()); BindingState state = new BindingState(configuration); KeyBinder keyBinder = new KeyBinder(FakeBindMethods.BindMethodReturningASingleDog); var result = InnerPathTokenBinder.GetNavigationNode(property, parent, null, state, keyBinder); result.ShouldBeCollectionNavigationNode(property); }
public void GetNavigationNodeCreatesSingleNavigationNodeForSingleMultiplicityProperty() { IEdmNavigationProperty property = HardCodedTestModel.GetPersonMyDogNavProp(); IEdmNavigationSource navigationSource; SingleResourceNode parent = new SingleResourceCastNode(null, HardCodedTestModel.GetDogType()); BindingState state = new BindingState(Configuration); KeyBinder keyBinder = new KeyBinder(FakeBindMethods.BindMethodReturningASingleDog); var result = InnerPathTokenBinder.GetNavigationNode(property, parent, null, state, keyBinder, out navigationSource); result.ShouldBeSingleNavigationNode(property); }