#feature: improve Jira planning and release branch creation
This commit is contained in:
@@ -176,6 +176,32 @@ class JiraServiceTest extends TestCase
|
||||
$this->assertEquals('本周完成的任务', $result['title']);
|
||||
}
|
||||
|
||||
public function test_build_next_week_tasks_jql_includes_developer_owner_for_requirements()
|
||||
{
|
||||
$reflection = new \ReflectionClass($this->jiraService);
|
||||
$method = $reflection->getMethod('buildNextWeekTasksJql');
|
||||
|
||||
$result = $method->invoke($this->jiraService, 'test-user', ['需求已评审', '需求已排期', '开发中'], 'cf[11000]');
|
||||
|
||||
$this->assertEquals(
|
||||
'(assignee = "test-user" OR cf[11000] = "test-user") AND status IN ("需求已评审", "需求已排期", "开发中") AND issuetype in ("Story", "需求") AND Sprint is not EMPTY ORDER BY created ASC',
|
||||
$result
|
||||
);
|
||||
}
|
||||
|
||||
public function test_build_next_week_tasks_jql_keeps_assignee_only_when_owner_field_missing()
|
||||
{
|
||||
$reflection = new \ReflectionClass($this->jiraService);
|
||||
$method = $reflection->getMethod('buildNextWeekTasksJql');
|
||||
|
||||
$result = $method->invoke($this->jiraService, 'test-user', ['需求已评审', '需求已排期', '开发中'], null);
|
||||
|
||||
$this->assertEquals(
|
||||
'assignee = "test-user" AND status IN ("需求已评审", "需求已排期", "开发中") AND issuetype in ("Story", "需求") AND Sprint is not EMPTY ORDER BY created ASC',
|
||||
$result
|
||||
);
|
||||
}
|
||||
|
||||
public function test_extract_sprint_info_from_string()
|
||||
{
|
||||
$reflection = new \ReflectionClass($this->jiraService);
|
||||
|
||||
Reference in New Issue
Block a user