public void TranslateWithBatchSegmentReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = BatchSegment.Instance; Assert.False(translator.Translate(segment)); }
public void TranslateWithDynamicPathSegmentReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new DynamicPathSegment("test"); Assert.False(translator.Translate(segment)); }
public void TranslateWithNavigationPropertyLinkSegmentReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new NavigationPropertyLinkSegment(HardCodedTestModel.GetPersonMyDogNavProp(), null); Assert.False(translator.Translate(segment)); }
public void TranslateWithEntitySetSegmentReturnsTrue() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new EntitySetSegment(HardCodedTestModel.GetPeopleSet()); Assert.True(translator.Translate(segment)); }
public void TranslateWithPropertySetSegmentReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new PropertySegment(HardCodedTestModel.GetDogColorProp()); Assert.False(translator.Translate(segment)); }
public void TranslateWithBatchSegmentReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = BatchSegment.Instance; translator.Translate(segment).Should().BeFalse(); }
public void TranslateWithDynamicPathSegmentReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new DynamicPathSegment("test"); translator.Translate(segment).Should().BeFalse(); }
public void TranslateWithNavigationPropertySegmentNonCollectionReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new NavigationPropertySegment(HardCodedTestModel.GetPersonMyDogNavProp(), null); translator.Translate(segment).Should().BeFalse(); }
public void TranslateWithBatchReferenceSegmentReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new BatchReferenceSegment( "$0", HardCodedTestModel.GetDogType(), HardCodedTestModel.GetDogsSet()); Assert.False(translator.Translate(segment)); }
public void TranslateWithValueSegmentReturnsThrows() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new ValueSegment(ModelBuildingHelpers.BuildValidEntityType()); Action translateAction = () => translator.Translate(segment); translateAction.Throws <NotImplementedException>(segment.ToString()); }
public void TranslateWithKeySetSegmentReturnsFalse() { IsCollectionTranslator translator = new IsCollectionTranslator(); var segment = new KeySegment( new List <KeyValuePair <string, object> >(), ModelBuildingHelpers.BuildValidEntityType(), null); Assert.False(translator.Translate(segment)); }