def test_create_issues_with_priority(self):
    self.client.force_authenticate(user=get_user_model().objects.get(username='app_owner_user'))
    response = self.client.post(reverse('issues-list'), {'priority': '紧急', 'appId': 1, 'taskId': 1, 'statusId': 1, 'title': 'aaaa', 'detail': 'bbbb'})
    self.assertEqual(response.status_code, status.HTTP_200_OK)
    self.assertEqual(response.data['data']['priority'], '紧急')
    response = self.client.post(reverse('issues-list'), {'appId': 1, 'taskId': 1, 'statusId': 1, 'title': 'aaaa', 'detail': 'bbbb'})
    self.assertEqual(response.status_code, status.HTTP_200_OK)
    self.assertEqual(response.data['data']['priority'], '一般')
    response = self.client.get(reverse('issues-list'), {'priority': '紧急', 'appId': 1})
    self.assertEqual(self._get_response_total(response), 1)
    response = self.client.get(reverse('issues-list'), {'priority': '一般', 'appId': 1})
    self.assertEqual(self._get_response_total(response), 1)
def test_create_issues_with_priority(self):
    self.client.force_authenticate(user=get_user_model().objects.get(username='app_owner_user'))
    response = self.client.post(reverse('issues-list'), {'priority': '紧急', 'appId': 1, 'taskId': 1, 'statusId': 1, 'title': 'aaaa', 'detail': 'bbbb'})
    self.assertEqual(response.status_code, status.HTTP_200_OK)
    self.assertEqual(response.data['data']['priority'], '紧急')
    response = self.client.post(reverse('issues-list'), {'appId': 1, 'taskId': 1, 'statusId': 1, 'title': 'aaaa', 'detail': 'bbbb'})
    self.assertEqual(response.status_code, status.HTTP_200_OK)
    self.assertEqual(response.data['data']['priority'], '一般')
    response = self.client.get(reverse('issues-list'), {'priority': '紧急', 'appId': 1})
    self.assertEqual(self._get_response_total(response), 1)
    response = self.client.get(reverse('issues-list'), {'priority': '一般', 'appId': 1})
    self.assertEqual(self._get_response_total(response), 1)