Versions in this module Expand all Collapse all v1 v1.0.1 Aug 15, 2024 Changes in this version + const ApiTestIDs + const ApiTestType + const PipelineStageLen + const PipelineYmlVersion + const UsecaseID + type Option func(*Service) + func WithBundle(bdl *bundle.Bundle) Option + func WithDBClient(db *dao.DBClient) Option + func WithIssueDBClient(db *issuedao.DBClient) Option + func WithOrg(org org.Interface) Option + func WithPipelineSvc(pipelineSvc pipelinepb.PipelineServiceServer) Option + type Service struct + CreateTestSetFn func(apistructs.TestSetCreateRequest) (*apistructs.TestSet, error) + func New(options ...Option) *Service + func (svc *Service) BatchCleanFromRecycleBin(req apistructs.TestCaseBatchCleanFromRecycleBinRequest) error + func (svc *Service) BatchClearProcessingRecords() error + func (svc *Service) BatchCopyTestCases(req apistructs.TestCaseBatchCopyRequest) ([]uint64, error) + func (svc *Service) BatchCreateTestCases(req apistructs.TestCaseBatchCreateRequest) ([]uint64, error) + func (svc *Service) BatchListAPIs(projectID uint64, tcIDs []uint64) (map[uint64][]*apistructs.ApiTestInfo, error) + func (svc *Service) BatchUpdateTestCases(req apistructs.TestCaseBatchUpdateRequest) error + func (svc *Service) CreateAPI(req apistructs.ApiTestsCreateRequest) (*apistructs.ApiTestInfo, error) + func (svc *Service) CreateFileRecord(req apistructs.TestFileRecordRequest) (uint64, error) + func (svc *Service) CreateTestCase(req apistructs.TestCaseCreateRequest) (uint64, error) + func (svc *Service) DeleteAPI(apiID int64) error + func (svc *Service) DeleteRecordApiFilesByTime(t time.Time) error + func (svc *Service) ExecuteAPIs(req apistructs.ApiTestsActionRequest) (uint64, error) + func (svc *Service) Export(req apistructs.TestCaseExportRequest) (uint64, error) + func (svc *Service) ExportAIGenerated(req apistructs.TestCaseExportRequest) (uint64, error) + func (svc *Service) ExportFile(record *dao.TestFileRecord) + func (svc *Service) ExportTestCases(req *apistructs.TestCaseExportRequest, sheetName string, needQuery bool) (string, error) + func (svc *Service) GetAPI(apiID int64) (*apistructs.ApiTestInfo, error) + func (svc *Service) GetFileRecord(id uint64, locale string) (*apistructs.TestFileRecord, error) + func (svc *Service) GetFirstFileReady(actionType ...apistructs.FileActionType) (bool, *dao.TestFileRecord, error) + func (svc *Service) GetTestCase(tcID uint64) (*apistructs.TestCase, error) + func (svc *Service) Import(req apistructs.TestCaseImportRequest, r *http.Request) (*apistructs.TestCaseImportResult, error) + func (svc *Service) ImportFile(record *dao.TestFileRecord) + func (svc *Service) ImportTestCases(req *apistructs.TestCaseImportRequest, testFileUUID string) error + func (svc *Service) ListAPIs(testCaseID int64) ([]*apistructs.ApiTestInfo, error) + func (svc *Service) ListFileRecords(req apistructs.ListTestFileRecordsRequest) ([]apistructs.TestFileRecord, []string, map[string]int, int, error) + func (svc *Service) ListTestCases(req apistructs.TestCaseListRequest) ([]apistructs.TestCase, []uint64, error) + func (svc *Service) ListTestCasesDeep(req apistructs.TestCaseListRequest) ([]uint64, error) + func (svc *Service) MarkFileRecordAsTimeout(timeout time.Duration) error + func (svc *Service) PagingTestCases(req apistructs.TestCasePagingRequest) (*apistructs.TestCasePagingResponseData, error) + func (svc *Service) UpdateAPI(req apistructs.ApiTestsUpdateRequest) (int64, error) + func (svc *Service) UpdateFileRecord(req apistructs.TestFileRecordRequest) error + func (svc *Service) UpdateTestCase(req apistructs.TestCaseUpdateRequest) error