public void Two() { AssertQuery(Source <JiraIssue>() .Where(x => JqlFunctions.Contains(x.Summary, "test")) .Where(x => x.Parent == "SOME_KEY"), "((summary ~ \"test\") AND (parent = \"SOME_KEY\"))"); }
public void ParentsOf() { AssertQuery(Source <JiraIssue>() .Where(x => Source <JiraIssue>() .Where(y => JqlFunctions.Contains(y.Summary, "test")) .Any(y => y.Parent == x)), "(ISSUEFUNCTION IN PARENTSOF(\"(summary ~ \\\"test\\\")\"))"); }
public void SubTasksOf() { AssertQuery(Source <JiraIssue>() .Where(x => Source <JiraIssue>() .Where(y => JqlFunctions.Contains(y.Summary, "test")) .Any(y => y == x.Parent)), "(ISSUEFUNCTION IN SUBTASKSOF(\"(summary ~ \\\"test\\\")\"))"); }
public void ParentsOf_Complex() { AssertQuery(Source <JiraIssue>() .Where(x => x.Key == "TEST_KEY") .Where(x => Source <JiraIssue>() .Where(y => JqlFunctions.Contains(y.Summary, "test")) .Any(y => y.Parent == x)), "((key = \"TEST_KEY\") AND (ISSUEFUNCTION IN PARENTSOF(\"(summary ~ \\\"test\\\")\")))"); }
public async Task False() { await jira.CreateIssueAsync(new JiraIssue { Project = TestMetadata.Project, IssueType = TestMetadata.IssueType, Summary = "Тестовая тема" }, CancellationToken.None); AssertEmpty(Source <JiraCustomIssue>() .Where(x => JqlFunctions.Contains(x.Summary, Guid.NewGuid().ToString()))); }
public async Task True() { var reference = await jira.CreateIssueAsync(new JiraIssue { Project = TestMetadata.Project, IssueType = TestMetadata.IssueType, Summary = "Тестовая тема" }, CancellationToken.None); AssertSingle(Source <JiraCustomIssue>() .Where(x => JqlFunctions.Contains(x.Summary, "тема")), reference); }
public async Task Test() { for (var i = 0; i < 1643; ++i) { await jira.CreateIssueAsync(new JiraCustomIssue { Project = TestProject, IssueType = TestMetadata.IssueType, Summary = "Тестовая тема" }, CancellationToken.None); } Assert.That( Source <JiraCustomIssue>().Any(x => JqlFunctions.Contains(x.Summary, "тема")), Is.True); }