Пример #1
0
 public void SpecifyingAWildCardShouldNotCauseDuplicates()
 {
     SelectedPropertiesNode.Create("Districts,*,Photo").Should().HaveStreams(this.cityType, "Photo").And.HaveNavigations(this.cityType, "Districts").And.HaveChild(this.cityType, "Districts", c => c.Should().BeSameAsEntireSubtree());
 }
Пример #2
0
 public void OpenTypeWithoutContainerQualifiedNameShouldNotIncludeAction()
 {
     SelectedPropertiesNode.Create("Action").Should().NotHaveAction(this.openType, this.action);
 }
Пример #3
0
 public void GetSelectedPropertiesForNavigationPropertyForNonEmptyNodeShouldAlwaysReturnEntireSubtreeWhenEntityTypeIsNull()
 {
     EntireSubtreeNode.GetSelectedPropertiesForNavigationProperty(entityType: null, navigationPropertyName: "foo").Should().BeSameAs(EntireSubtreeNode);
     SelectedPropertiesNode.Create("bar").GetSelectedPropertiesForNavigationProperty(entityType: null, navigationPropertyName: "foo").Should().BeSameAs(EntireSubtreeNode);
 }
Пример #4
0
 public void BaseTypeSegmentBeforeActionNameShouldIncludeAction()
 {
     SelectedPropertiesNode.Create("TestModel.City/Action").Should().HaveAction(this.metropolisType, this.action);
 }
Пример #5
0
 public void ExactTypeSegmentBeforeContainerQualifiedWildCardShouldIncludeAction()
 {
     SelectedPropertiesNode.Create("TestModel.City/TestModel.*").Should().HaveAction(this.cityType, this.action);
 }
Пример #6
0
 public void NamespaceQualifiedWildcardShouldIncludeAction()
 {
     SelectedPropertiesNode.Create("TestModel.*").Should().HaveAction(this.cityType, this.action);
 }
Пример #7
0
 public void NamespaceAndContainerQualifiedNameWithParametersShouldIncludeAction()
 {
     SelectedPropertiesNode.Create("TestModel.Action(Edm.Int32)").Should().HaveAction(this.cityType, this.action);
 }
Пример #8
0
 public void TypeSegmentWithNavigationUsingBaseTypeName()
 {
     SelectedPropertiesNode.Create("TestModel.City/Districts").Should().HaveOnlyNavigations(this.metropolisType, "Districts");
 }
Пример #9
0
 public void MultipleTypeSegmentsShouldNotProduceDuplicateStreams()
 {
     SelectedPropertiesNode.Create("TestModel.Town/Photo,TestModel.City/Photo").Should().HaveOnlyStreams(this.cityType, "Photo");
 }
Пример #10
0
 public void UnmatchedTypeSegments()
 {
     SelectedPropertiesNode.Create("TestModel.Fake/Photo,TestModel.Fake2/Districts").Should().NotHaveStreams(this.cityType).And.NotHaveNavigations(this.cityType);
 }
Пример #11
0
 public void TypeSegmentWithStreamUsingBaseTypeName()
 {
     SelectedPropertiesNode.Create("TestModel.City/Photo").Should().HaveOnlyStreams(this.metropolisType, "Photo");
 }
Пример #12
0
 public void SimpleTypeSegmentWithNavigation()
 {
     SelectedPropertiesNode.Create("TestModel.City/Districts").Should().HaveOnlyNavigations(this.cityType, "Districts");
 }
Пример #13
0
 public void SimpleTypeSegmentWithStream()
 {
     SelectedPropertiesNode.Create("TestModel.City/Photo").Should().HaveOnlyStreams(this.cityType, "Photo");
 }
Пример #14
0
 public void SelectingANavigationShouldSelectTheEntireTreeIfWildcardAlsoPresent()
 {
     SelectedPropertiesNode.Create("Districts,Districts/*").Should().HaveOnlyNavigations(this.cityType, "Districts").And.HaveChild(this.cityType, "Districts", c => c.Should().BeSameAsEntireSubtree());
 }
Пример #15
0
 public void SpecificActionWithParametersShouldBeSelected()
 {
     SelectedPropertiesNode.Create("Action(Edm.Int32)").Should().HaveAction(this.cityType, this.action);
 }
Пример #16
0
 public void MultipleTypeSegmentsShouldNotProduceDuplicateNavigations()
 {
     SelectedPropertiesNode.Create("TestModel.City/Districts,TestModel.Metropolis/Districts").Should().HaveOnlyNavigations(this.metropolisType, "Districts");
 }
Пример #17
0
 public void NamespaceQualifiedActionNameShouldBeSelected()
 {
     SelectedPropertiesNode.Create("TestModel.Action").Should().HaveAction(this.cityType, this.action);
 }
Пример #18
0
 public void StreamSpecifiedInBothTypeSegmentAndDirectlyShouldNotProduceDuplicates()
 {
     SelectedPropertiesNode.Create("TestModel.City/Photo,Photo").Should().HaveOnlyStreams(this.cityType, "Photo");
 }
Пример #19
0
 public void UnQualifiedNameWithParametersShouldNotIncludeActionOnOpenType()
 {
     SelectedPropertiesNode.Create("Action(Edm.Int32)").Should().NotHaveAction(this.openType, this.action);
 }
Пример #20
0
 public void NavigationSpecifiedInBothTypeSegmentAndDirectlyShouldNotProduceDuplicates()
 {
     SelectedPropertiesNode.Create("TestModel.City/Districts,Districts").Should().HaveOnlyNavigations(this.cityType, "Districts");
 }
Пример #21
0
 public void WrongTypeSegmentBeforeActionNameShouldNotIncludeAction()
 {
     SelectedPropertiesNode.Create("FQNS.Fake/Action").Should().NotHaveAction(this.cityType, this.action);
 }
Пример #22
0
 public void SubPropertyOfNavigationSpecifiedInBothTypeSegmentAndDirectlyShouldNotProduceDuplicates()
 {
     SelectedPropertiesNode.Create("TestModel.City/Districts/Thumbnail,Districts/Thumbnail").Should()
     .HaveOnlyNavigations(this.cityType, "Districts")
     .And.HaveChild(this.cityType, "Districts", c => c.Should().HaveOnlyStreams(this.districtType, "Thumbnail"));
 }
Пример #23
0
 public void DerivedTypeSegmentBeforeActionNameShouldNotIncludeAction()
 {
     SelectedPropertiesNode.Create("TestModel.Metropolis/Action").Should().NotHaveAction(this.cityType, this.action);
 }
Пример #24
0
 public void WildCardShouldNotIncludeActions()
 {
     SelectedPropertiesNode.Create("*").Should().NotHaveAction(this.cityType, this.action);
 }
Пример #25
0
 public void ActionsMustBeFullQualifiedIfConflictWithPropertyShouldIncludeAction()
 {
     SelectedPropertiesNode.Create("TestModel.Zip").Should().HaveAction(this.districtType, this.actionConflictingWithPropertyName);
 }
Пример #26
0
 public void SpecificActionShouldBeNotSelectedForNonMatchingName()
 {
     SelectedPropertiesNode.Create("foo").Should().NotHaveAction(this.cityType, this.action);
 }
Пример #27
0
 public void OpenTypeWithContainerQualifiedNameShouldIncludeAction()
 {
     SelectedPropertiesNode.Create("TestModel.Action").Should().HaveAction(this.openType, this.action);
 }
Пример #28
0
 public void SpecificActionShouldBeSelected()
 {
     SelectedPropertiesNode.Create("Action").Should().HaveAction(this.cityType, this.action);
 }
Пример #29
0
 public void GetSelectedNavigationPropertiesShouldAlwaysReturnEmptyEnumerationWhenEntityTypeIsNull()
 {
     EntireSubtreeNode.GetSelectedNavigationProperties(entityType: null).Should().BeEmpty();
     EmptyNode.GetSelectedNavigationProperties(entityType: null).Should().BeEmpty();
     SelectedPropertiesNode.Create("bar").GetSelectedNavigationProperties(entityType: null).Should().BeEmpty();
 }
Пример #30
0
 public void SpecifyingTheSameNavigationTwiceShouldNotCauseDuplicates()
 {
     SelectedPropertiesNode.Create("Districts,Districts").Should().HaveOnlyNavigations(this.cityType, "Districts").And.HaveChild(this.cityType, "Districts", c => c.Should().BeSameAsEntireSubtree());
 }