public void SubDoc_More_Than_One_XAttr_Is_Allowed() { var builder = new LookupInSpecBuilder(); builder.Get("doc.path", isXattr: true) .Get("path", isXattr: true) .Get("notXattr", false); builder.Specs.ToArray(); }
public void SubDoc_XAttr_Can_Come_Out_Of_Order() { var builder = new LookupInSpecBuilder(); builder.Get("doc.path", isXattr: true) .Get("notXattr", false) .Get("path", isXattr: true); builder.Specs.ToArray(); }
public void Get_WithDynamicExpression_AddsSpec() { // Arrange var builder = new LookupInSpecBuilder <MyDoc>(new DefaultSerializer()); // Act builder.Get(p => p.Dynamic); // Assert var spec = Assert.Single(builder.Specs); Assert.NotNull(spec); Assert.Equal("`dynamic`", spec.Path); Assert.Equal(OpCode.SubGet, spec.OpCode); }