qaTestCaseHandler saves a record into the `qa_test_cases` table
(qaProjectId string)
| 505 | |
| 506 | // qaTestCaseHandler saves a record into the `qa_test_cases` table |
| 507 | func (s *Service) qaTestCaseHandler(qaProjectId string) func(record map[string]interface{}) errors.Error { |
| 508 | return func(record map[string]interface{}) errors.Error { |
| 509 | creatorName, _ := getStringField(record, "creator_name", false) |
| 510 | if creatorName != "" { |
| 511 | creatorId, _ := s.createOrUpdateAccount(creatorName, qaProjectId) |
| 512 | record["creator_id"] = creatorId |
| 513 | } |
| 514 | // remove fields |
| 515 | delete(record, "creator_name") |
| 516 | record["qa_project_id"] = qaProjectId |
| 517 | return s.dal.CreateWithMap(&qa.QaTestCase{}, record) |
| 518 | } |
| 519 | } |
| 520 | |
| 521 | // ImportQaTestCaseExecutions imports csv file to the table `qa_test_case_executions` |
| 522 | func (s *Service) ImportQaTestCaseExecutions(qaProjectId string, file io.ReadCloser, incremental bool) errors.Error { |
no test coverage detected