public void SelectAll() { var selectString = "*"; ODataUriParser parser = this.CreateSelectUriParser(peopleBase, selectString); var result = parser.ParseSelectAndExpand(); ApprovalVerify(QueryNodeToStringVisitor.GetTestCaseAndResultString(result, selectString, null)); }
public void SelectFunction() { var selectString = "Microsoft.Test.Taupo.OData.WCFService.GetOrderRate"; ODataUriParser parser = this.CreateSelectUriParser(orderBase, selectString); var result = parser.ParseSelectAndExpand(); ApprovalVerify(QueryNodeToStringVisitor.GetTestCaseAndResultString(result, selectString, null)); }
public void RedundantlyParserFilter() { const string queryOption = "AssociatedOrder($filter=CustomerID eq null)"; ODataUriParser parser = this.CreateExpandUriParser(orderDetailBase, queryOption); var result = parser.ParseSelectAndExpand(); ApprovalVerify(QueryNodeToStringVisitor.GetTestCaseAndResultString(result, null, queryOption)); result = parser.ParseSelectAndExpand(); ApprovalVerify(QueryNodeToStringVisitor.GetTestCaseAndResultString(result, null, queryOption)); }
private void TestAllInOneExtensionFilter(Uri baseUri, string filter, string origFilter) { this.TestExtension( this.CreateFilterUriParser(baseUri, filter), new AllInOneResolver() { EnableCaseInsensitive = true }, parser => parser.ParseFilter(), clause => QueryNodeToStringVisitor.GetTestCaseAndResultString(clause, origFilter), this.ApprovalVerify); }
private void TestAllInOneExtensionOrderBy(Uri baseUri, string orderby, string origOrderby) { this.TestExtension( this.CreateOrderByUriParser(baseUri, orderby), new AllInOneResolver() { EnableCaseInsensitive = true }, parser => parser.ParseOrderBy(), clause => QueryNodeToStringVisitor.GetTestCaseAndResultString(clause, origOrderby), this.ApprovalVerify); }
public void RedundantlyParserFilter() { const string queryOption = "CustomerID eq null"; ODataUriParser parser = this.CreateFilterUriParser(orderBase, queryOption); var result = parser.ParseFilter(); ApprovalVerify(QueryNodeToStringVisitor.GetTestCaseAndResultString(result, queryOption)); result = parser.ParseFilter(); ApprovalVerify(QueryNodeToStringVisitor.GetTestCaseAndResultString(result, queryOption)); this.TestAllInOneExtensionFilter( orderBase, "customerid eQ null", "CustomerID eq null"); }