Documentation ¶
Overview ¶
Package result is a generated GoMock package.
Index ¶
- Constants
- func NewExecutionsFilter() *filter
- type ExecutionOutput
- type Filter
- type MockRepository
- func (m *MockRepository) DeleteAll(ctx context.Context) error
- func (m *MockRepository) DeleteAllOutput(ctx context.Context) error
- func (m *MockRepository) DeleteByTest(ctx context.Context, testName string) error
- func (m *MockRepository) DeleteByTestSuite(ctx context.Context, testSuiteName string) error
- func (m *MockRepository) DeleteByTestSuites(ctx context.Context, testSuiteNames []string) error
- func (m *MockRepository) DeleteByTests(ctx context.Context, testNames []string) error
- func (m *MockRepository) DeleteForAllTestSuites(ctx context.Context) error
- func (m *MockRepository) DeleteOutput(ctx context.Context, id string) error
- func (m *MockRepository) DeleteOutputByTest(ctx context.Context, testName string) error
- func (m *MockRepository) DeleteOutputByTestSuite(ctx context.Context, testSuiteName string) error
- func (m *MockRepository) DeleteOutputForAllTestSuite(ctx context.Context) error
- func (m *MockRepository) DeleteOutputForTestSuites(ctx context.Context, testSuiteNames []string) error
- func (m *MockRepository) DeleteOutputForTests(ctx context.Context, testNames []string) error
- func (m *MockRepository) EXPECT() *MockRepositoryMockRecorder
- func (m *MockRepository) EndExecution(ctx context.Context, execution testkube.Execution) error
- func (m *MockRepository) Get(ctx context.Context, id string) (testkube.Execution, error)
- func (m *MockRepository) GetByNameAndTest(ctx context.Context, name, testName string) (testkube.Execution, error)
- func (m *MockRepository) GetExecutionTotals(ctx context.Context, paging bool, filter ...Filter) (testkube.ExecutionsTotals, error)
- func (m *MockRepository) GetExecutions(ctx context.Context, filter Filter) ([]testkube.Execution, error)
- func (m *MockRepository) GetLabels(ctx context.Context) (map[string][]string, error)
- func (m *MockRepository) GetLatestByTest(ctx context.Context, testName, sortField string) (testkube.Execution, error)
- func (m *MockRepository) GetLatestByTests(ctx context.Context, testNames []string, sortField string) ([]testkube.Execution, error)
- func (m *MockRepository) GetNextExecutionNumber(ctx context.Context, testName string) (int32, error)
- func (m *MockRepository) GetOutput(ctx context.Context, id string) (string, error)
- func (m *MockRepository) GetOutputByTest(ctx context.Context, testName string) (string, error)
- func (m *MockRepository) GetOutputByTestSuite(ctx context.Context, testSuiteName string) (string, error)
- func (m *MockRepository) GetTestMetrics(ctx context.Context, name string, limit, last int) (testkube.ExecutionsMetrics, error)
- func (m *MockRepository) Insert(ctx context.Context, result testkube.Execution) error
- func (m *MockRepository) InsertOutput(ctx context.Context, id, testName, testSuiteName, output string) error
- func (m *MockRepository) StartExecution(ctx context.Context, id string, startTime time.Time) error
- func (m *MockRepository) Update(ctx context.Context, result testkube.Execution) error
- func (m *MockRepository) UpdateOutput(ctx context.Context, id, output string) error
- func (m *MockRepository) UpdateResult(ctx context.Context, id string, execution testkube.ExecutionResult) error
- type MockRepositoryMockRecorder
- func (mr *MockRepositoryMockRecorder) DeleteAll(ctx interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteAllOutput(ctx interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteByTest(ctx, testName interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteByTestSuite(ctx, testSuiteName interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteByTestSuites(ctx, testSuiteNames interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteByTests(ctx, testNames interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteForAllTestSuites(ctx interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteOutput(ctx, id interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteOutputByTest(ctx, testName interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteOutputByTestSuite(ctx, testSuiteName interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteOutputForAllTestSuite(ctx interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteOutputForTestSuites(ctx, testSuiteNames interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) DeleteOutputForTests(ctx, testNames interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) EndExecution(ctx, execution interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) Get(ctx, id interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetByNameAndTest(ctx, name, testName interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetExecutionTotals(ctx, paging interface{}, filter ...interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetExecutions(ctx, filter interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetLabels(ctx interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetLatestByTest(ctx, testName, sortField interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetLatestByTests(ctx, testNames, sortField interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetNextExecutionNumber(ctx, testName interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetOutput(ctx, id interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetOutputByTest(ctx, testName interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetOutputByTestSuite(ctx, testSuiteName interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) GetTestMetrics(ctx, name, limit, last interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) Insert(ctx, result interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) InsertOutput(ctx, id, testName, testSuiteName, output interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) StartExecution(ctx, id, startTime interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) Update(ctx, result interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) UpdateOutput(ctx, id, output interface{}) *gomock.Call
- func (mr *MockRepositoryMockRecorder) UpdateResult(ctx, id, execution interface{}) *gomock.Call
- type MongoRepository
- func (r *MongoRepository) DeleteAll(ctx context.Context) (err error)
- func (m *MongoRepository) DeleteAllOutput(ctx context.Context) error
- func (r *MongoRepository) DeleteByTest(ctx context.Context, testName string) (err error)
- func (r *MongoRepository) DeleteByTestSuite(ctx context.Context, testSuiteName string) (err error)
- func (r *MongoRepository) DeleteByTestSuites(ctx context.Context, testSuiteNames []string) (err error)
- func (r *MongoRepository) DeleteByTests(ctx context.Context, testNames []string) (err error)
- func (r *MongoRepository) DeleteForAllTestSuites(ctx context.Context) (err error)
- func (m *MongoRepository) DeleteOutput(ctx context.Context, id string) error
- func (m *MongoRepository) DeleteOutputByTest(ctx context.Context, testName string) error
- func (m *MongoRepository) DeleteOutputByTestSuite(ctx context.Context, testSuiteName string) error
- func (m *MongoRepository) DeleteOutputForAllTestSuite(ctx context.Context) error
- func (m *MongoRepository) DeleteOutputForTestSuites(ctx context.Context, testSuiteNames []string) error
- func (m *MongoRepository) DeleteOutputForTests(ctx context.Context, testNames []string) error
- func (r *MongoRepository) EndExecution(ctx context.Context, e testkube.Execution) (err error)
- func (r *MongoRepository) Get(ctx context.Context, id string) (result testkube.Execution, err error)
- func (r *MongoRepository) GetByNameAndTest(ctx context.Context, name, testName string) (result testkube.Execution, err error)
- func (r *MongoRepository) GetExecutionTotals(ctx context.Context, paging bool, filter ...Filter) (totals testkube.ExecutionsTotals, err error)
- func (r *MongoRepository) GetExecutions(ctx context.Context, filter Filter) (result []testkube.Execution, err error)
- func (r *MongoRepository) GetLabels(ctx context.Context) (labels map[string][]string, err error)
- func (r *MongoRepository) GetLatestByTest(ctx context.Context, testName, sortField string) (result testkube.Execution, err error)
- func (r *MongoRepository) GetLatestByTests(ctx context.Context, testNames []string, sortField string) (executions []testkube.Execution, err error)
- func (r *MongoRepository) GetNewestExecutions(ctx context.Context, limit int) (result []testkube.Execution, err error)
- func (r *MongoRepository) GetNextExecutionNumber(ctx context.Context, testName string) (number int32, err error)
- func (r *MongoRepository) GetOutput(ctx context.Context, id string) (output string, err error)
- func (m *MongoRepository) GetOutputByTest(ctx context.Context, testName string) (output string, err error)
- func (m *MongoRepository) GetOutputByTestSuite(ctx context.Context, testSuiteName string) (output string, err error)
- func (r *MongoRepository) GetTestMetrics(ctx context.Context, name string, limit, last int) (metrics testkube.ExecutionsMetrics, err error)
- func (r *MongoRepository) Insert(ctx context.Context, result testkube.Execution) (err error)
- func (m *MongoRepository) InsertOutput(ctx context.Context, id, testName, testSuiteName, output string) error
- func (r *MongoRepository) StartExecution(ctx context.Context, id string, startTime time.Time) (err error)
- func (r *MongoRepository) Update(ctx context.Context, result testkube.Execution) (err error)
- func (m *MongoRepository) UpdateOutput(ctx context.Context, id, output string) error
- func (r *MongoRepository) UpdateResult(ctx context.Context, id string, result testkube.ExecutionResult) (err error)
- type OutputRepository
- type Repository
- type Sequences
Constants ¶
const ( CollectionName = "results" CollectionSequences = "sequences" CollectionOutput = "output" )
const PageDefaultLimit int = 100
Variables ¶
This section is empty.
Functions ¶
func NewExecutionsFilter ¶ added in v0.6.9
func NewExecutionsFilter() *filter
Types ¶
type ExecutionOutput ¶ added in v1.8.8
type Filter ¶ added in v0.6.9
type Filter interface { TestName() string TestNameDefined() bool LastNDays() int LastNDaysDefined() bool StartDate() time.Time StartDateDefined() bool EndDate() time.Time EndDateDefined() bool Statuses() testkube.ExecutionStatuses StatusesDefined() bool Page() int PageSize() int TextSearchDefined() bool TextSearch() string Selector() string TypeDefined() bool Type() string }
type MockRepository ¶ added in v1.5.33
type MockRepository struct {
// contains filtered or unexported fields
}
MockRepository is a mock of Repository interface.
func NewMockRepository ¶ added in v1.5.33
func NewMockRepository(ctrl *gomock.Controller) *MockRepository
NewMockRepository creates a new mock instance.
func (*MockRepository) DeleteAll ¶ added in v1.5.33
func (m *MockRepository) DeleteAll(ctx context.Context) error
DeleteAll mocks base method.
func (*MockRepository) DeleteAllOutput ¶ added in v1.8.8
func (m *MockRepository) DeleteAllOutput(ctx context.Context) error
DeleteAllOutput mocks base method.
func (*MockRepository) DeleteByTest ¶ added in v1.5.33
func (m *MockRepository) DeleteByTest(ctx context.Context, testName string) error
DeleteByTest mocks base method.
func (*MockRepository) DeleteByTestSuite ¶ added in v1.5.33
func (m *MockRepository) DeleteByTestSuite(ctx context.Context, testSuiteName string) error
DeleteByTestSuite mocks base method.
func (*MockRepository) DeleteByTestSuites ¶ added in v1.5.33
func (m *MockRepository) DeleteByTestSuites(ctx context.Context, testSuiteNames []string) error
DeleteByTestSuites mocks base method.
func (*MockRepository) DeleteByTests ¶ added in v1.5.33
func (m *MockRepository) DeleteByTests(ctx context.Context, testNames []string) error
DeleteByTests mocks base method.
func (*MockRepository) DeleteForAllTestSuites ¶ added in v1.5.33
func (m *MockRepository) DeleteForAllTestSuites(ctx context.Context) error
DeleteForAllTestSuites mocks base method.
func (*MockRepository) DeleteOutput ¶ added in v1.8.8
func (m *MockRepository) DeleteOutput(ctx context.Context, id string) error
DeleteOutput mocks base method.
func (*MockRepository) DeleteOutputByTest ¶ added in v1.8.8
func (m *MockRepository) DeleteOutputByTest(ctx context.Context, testName string) error
DeleteOutputByTest mocks base method.
func (*MockRepository) DeleteOutputByTestSuite ¶ added in v1.8.8
func (m *MockRepository) DeleteOutputByTestSuite(ctx context.Context, testSuiteName string) error
DeleteOutputByTestSuite mocks base method.
func (*MockRepository) DeleteOutputForAllTestSuite ¶ added in v1.8.8
func (m *MockRepository) DeleteOutputForAllTestSuite(ctx context.Context) error
DeleteOutputForAllTestSuite mocks base method.
func (*MockRepository) DeleteOutputForTestSuites ¶ added in v1.8.8
func (m *MockRepository) DeleteOutputForTestSuites(ctx context.Context, testSuiteNames []string) error
DeleteOutputForTestSuites mocks base method.
func (*MockRepository) DeleteOutputForTests ¶ added in v1.8.8
func (m *MockRepository) DeleteOutputForTests(ctx context.Context, testNames []string) error
DeleteOutputForTests mocks base method.
func (*MockRepository) EXPECT ¶ added in v1.5.33
func (m *MockRepository) EXPECT() *MockRepositoryMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockRepository) EndExecution ¶ added in v1.5.33
EndExecution mocks base method.
func (*MockRepository) GetByNameAndTest ¶ added in v1.5.33
func (m *MockRepository) GetByNameAndTest(ctx context.Context, name, testName string) (testkube.Execution, error)
GetByNameAndTest mocks base method.
func (*MockRepository) GetExecutionTotals ¶ added in v1.5.33
func (m *MockRepository) GetExecutionTotals(ctx context.Context, paging bool, filter ...Filter) (testkube.ExecutionsTotals, error)
GetExecutionTotals mocks base method.
func (*MockRepository) GetExecutions ¶ added in v1.5.33
func (m *MockRepository) GetExecutions(ctx context.Context, filter Filter) ([]testkube.Execution, error)
GetExecutions mocks base method.
func (*MockRepository) GetLatestByTest ¶ added in v1.5.33
func (m *MockRepository) GetLatestByTest(ctx context.Context, testName, sortField string) (testkube.Execution, error)
GetLatestByTest mocks base method.
func (*MockRepository) GetLatestByTests ¶ added in v1.5.33
func (m *MockRepository) GetLatestByTests(ctx context.Context, testNames []string, sortField string) ([]testkube.Execution, error)
GetLatestByTests mocks base method.
func (*MockRepository) GetNextExecutionNumber ¶ added in v1.5.33
func (m *MockRepository) GetNextExecutionNumber(ctx context.Context, testName string) (int32, error)
GetNextExecutionNumber mocks base method.
func (*MockRepository) GetOutputByTest ¶ added in v1.8.8
GetOutputByTest mocks base method.
func (*MockRepository) GetOutputByTestSuite ¶ added in v1.8.8
func (m *MockRepository) GetOutputByTestSuite(ctx context.Context, testSuiteName string) (string, error)
GetOutputByTestSuite mocks base method.
func (*MockRepository) GetTestMetrics ¶ added in v1.5.33
func (m *MockRepository) GetTestMetrics(ctx context.Context, name string, limit, last int) (testkube.ExecutionsMetrics, error)
GetTestMetrics mocks base method.
func (*MockRepository) InsertOutput ¶ added in v1.8.8
func (m *MockRepository) InsertOutput(ctx context.Context, id, testName, testSuiteName, output string) error
InsertOutput mocks base method.
func (*MockRepository) StartExecution ¶ added in v1.5.33
StartExecution mocks base method.
func (*MockRepository) UpdateOutput ¶ added in v1.8.8
func (m *MockRepository) UpdateOutput(ctx context.Context, id, output string) error
UpdateOutput mocks base method.
func (*MockRepository) UpdateResult ¶ added in v1.5.33
func (m *MockRepository) UpdateResult(ctx context.Context, id string, execution testkube.ExecutionResult) error
UpdateResult mocks base method.
type MockRepositoryMockRecorder ¶ added in v1.5.33
type MockRepositoryMockRecorder struct {
// contains filtered or unexported fields
}
MockRepositoryMockRecorder is the mock recorder for MockRepository.
func (*MockRepositoryMockRecorder) DeleteAll ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) DeleteAll(ctx interface{}) *gomock.Call
DeleteAll indicates an expected call of DeleteAll.
func (*MockRepositoryMockRecorder) DeleteAllOutput ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) DeleteAllOutput(ctx interface{}) *gomock.Call
DeleteAllOutput indicates an expected call of DeleteAllOutput.
func (*MockRepositoryMockRecorder) DeleteByTest ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) DeleteByTest(ctx, testName interface{}) *gomock.Call
DeleteByTest indicates an expected call of DeleteByTest.
func (*MockRepositoryMockRecorder) DeleteByTestSuite ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) DeleteByTestSuite(ctx, testSuiteName interface{}) *gomock.Call
DeleteByTestSuite indicates an expected call of DeleteByTestSuite.
func (*MockRepositoryMockRecorder) DeleteByTestSuites ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) DeleteByTestSuites(ctx, testSuiteNames interface{}) *gomock.Call
DeleteByTestSuites indicates an expected call of DeleteByTestSuites.
func (*MockRepositoryMockRecorder) DeleteByTests ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) DeleteByTests(ctx, testNames interface{}) *gomock.Call
DeleteByTests indicates an expected call of DeleteByTests.
func (*MockRepositoryMockRecorder) DeleteForAllTestSuites ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) DeleteForAllTestSuites(ctx interface{}) *gomock.Call
DeleteForAllTestSuites indicates an expected call of DeleteForAllTestSuites.
func (*MockRepositoryMockRecorder) DeleteOutput ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) DeleteOutput(ctx, id interface{}) *gomock.Call
DeleteOutput indicates an expected call of DeleteOutput.
func (*MockRepositoryMockRecorder) DeleteOutputByTest ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) DeleteOutputByTest(ctx, testName interface{}) *gomock.Call
DeleteOutputByTest indicates an expected call of DeleteOutputByTest.
func (*MockRepositoryMockRecorder) DeleteOutputByTestSuite ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) DeleteOutputByTestSuite(ctx, testSuiteName interface{}) *gomock.Call
DeleteOutputByTestSuite indicates an expected call of DeleteOutputByTestSuite.
func (*MockRepositoryMockRecorder) DeleteOutputForAllTestSuite ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) DeleteOutputForAllTestSuite(ctx interface{}) *gomock.Call
DeleteOutputForAllTestSuite indicates an expected call of DeleteOutputForAllTestSuite.
func (*MockRepositoryMockRecorder) DeleteOutputForTestSuites ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) DeleteOutputForTestSuites(ctx, testSuiteNames interface{}) *gomock.Call
DeleteOutputForTestSuites indicates an expected call of DeleteOutputForTestSuites.
func (*MockRepositoryMockRecorder) DeleteOutputForTests ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) DeleteOutputForTests(ctx, testNames interface{}) *gomock.Call
DeleteOutputForTests indicates an expected call of DeleteOutputForTests.
func (*MockRepositoryMockRecorder) EndExecution ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) EndExecution(ctx, execution interface{}) *gomock.Call
EndExecution indicates an expected call of EndExecution.
func (*MockRepositoryMockRecorder) Get ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) Get(ctx, id interface{}) *gomock.Call
Get indicates an expected call of Get.
func (*MockRepositoryMockRecorder) GetByNameAndTest ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) GetByNameAndTest(ctx, name, testName interface{}) *gomock.Call
GetByNameAndTest indicates an expected call of GetByNameAndTest.
func (*MockRepositoryMockRecorder) GetExecutionTotals ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) GetExecutionTotals(ctx, paging interface{}, filter ...interface{}) *gomock.Call
GetExecutionTotals indicates an expected call of GetExecutionTotals.
func (*MockRepositoryMockRecorder) GetExecutions ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) GetExecutions(ctx, filter interface{}) *gomock.Call
GetExecutions indicates an expected call of GetExecutions.
func (*MockRepositoryMockRecorder) GetLabels ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) GetLabels(ctx interface{}) *gomock.Call
GetLabels indicates an expected call of GetLabels.
func (*MockRepositoryMockRecorder) GetLatestByTest ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) GetLatestByTest(ctx, testName, sortField interface{}) *gomock.Call
GetLatestByTest indicates an expected call of GetLatestByTest.
func (*MockRepositoryMockRecorder) GetLatestByTests ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) GetLatestByTests(ctx, testNames, sortField interface{}) *gomock.Call
GetLatestByTests indicates an expected call of GetLatestByTests.
func (*MockRepositoryMockRecorder) GetNextExecutionNumber ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) GetNextExecutionNumber(ctx, testName interface{}) *gomock.Call
GetNextExecutionNumber indicates an expected call of GetNextExecutionNumber.
func (*MockRepositoryMockRecorder) GetOutput ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) GetOutput(ctx, id interface{}) *gomock.Call
GetOutput indicates an expected call of GetOutput.
func (*MockRepositoryMockRecorder) GetOutputByTest ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) GetOutputByTest(ctx, testName interface{}) *gomock.Call
GetOutputByTest indicates an expected call of GetOutputByTest.
func (*MockRepositoryMockRecorder) GetOutputByTestSuite ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) GetOutputByTestSuite(ctx, testSuiteName interface{}) *gomock.Call
GetOutputByTestSuite indicates an expected call of GetOutputByTestSuite.
func (*MockRepositoryMockRecorder) GetTestMetrics ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) GetTestMetrics(ctx, name, limit, last interface{}) *gomock.Call
GetTestMetrics indicates an expected call of GetTestMetrics.
func (*MockRepositoryMockRecorder) Insert ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) Insert(ctx, result interface{}) *gomock.Call
Insert indicates an expected call of Insert.
func (*MockRepositoryMockRecorder) InsertOutput ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) InsertOutput(ctx, id, testName, testSuiteName, output interface{}) *gomock.Call
InsertOutput indicates an expected call of InsertOutput.
func (*MockRepositoryMockRecorder) StartExecution ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) StartExecution(ctx, id, startTime interface{}) *gomock.Call
StartExecution indicates an expected call of StartExecution.
func (*MockRepositoryMockRecorder) Update ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) Update(ctx, result interface{}) *gomock.Call
Update indicates an expected call of Update.
func (*MockRepositoryMockRecorder) UpdateOutput ¶ added in v1.8.8
func (mr *MockRepositoryMockRecorder) UpdateOutput(ctx, id, output interface{}) *gomock.Call
UpdateOutput indicates an expected call of UpdateOutput.
func (*MockRepositoryMockRecorder) UpdateResult ¶ added in v1.5.33
func (mr *MockRepositoryMockRecorder) UpdateResult(ctx, id, execution interface{}) *gomock.Call
UpdateResult indicates an expected call of UpdateResult.
type MongoRepository ¶
type MongoRepository struct { Coll *mongo.Collection Sequences *mongo.Collection Output *mongo.Collection // contains filtered or unexported fields }
func NewMongoRespository ¶
func NewMongoRespository(db *mongo.Database, allowDiskUse bool) *MongoRepository
func (*MongoRepository) DeleteAll ¶ added in v1.2.14
func (r *MongoRepository) DeleteAll(ctx context.Context) (err error)
DeleteAll deletes all execution results
func (*MongoRepository) DeleteAllOutput ¶ added in v1.8.8
func (m *MongoRepository) DeleteAllOutput(ctx context.Context) error
func (*MongoRepository) DeleteByTest ¶ added in v1.2.14
func (r *MongoRepository) DeleteByTest(ctx context.Context, testName string) (err error)
DeleteByTest deletes execution results by test
func (*MongoRepository) DeleteByTestSuite ¶ added in v1.3.2
func (r *MongoRepository) DeleteByTestSuite(ctx context.Context, testSuiteName string) (err error)
DeleteByTestSuite deletes execution results by test suite
func (*MongoRepository) DeleteByTestSuites ¶ added in v1.3.2
func (r *MongoRepository) DeleteByTestSuites(ctx context.Context, testSuiteNames []string) (err error)
DeleteByTestSuites deletes execution results by test suites
func (*MongoRepository) DeleteByTests ¶ added in v1.2.14
func (r *MongoRepository) DeleteByTests(ctx context.Context, testNames []string) (err error)
DeleteByTests deletes execution results by tests
func (*MongoRepository) DeleteForAllTestSuites ¶ added in v1.3.2
func (r *MongoRepository) DeleteForAllTestSuites(ctx context.Context) (err error)
DeleteForAllTestSuites deletes execution results for all test suites
func (*MongoRepository) DeleteOutput ¶ added in v1.8.8
func (m *MongoRepository) DeleteOutput(ctx context.Context, id string) error
func (*MongoRepository) DeleteOutputByTest ¶ added in v1.8.8
func (m *MongoRepository) DeleteOutputByTest(ctx context.Context, testName string) error
func (*MongoRepository) DeleteOutputByTestSuite ¶ added in v1.8.8
func (m *MongoRepository) DeleteOutputByTestSuite(ctx context.Context, testSuiteName string) error
func (*MongoRepository) DeleteOutputForAllTestSuite ¶ added in v1.8.8
func (m *MongoRepository) DeleteOutputForAllTestSuite(ctx context.Context) error
func (*MongoRepository) DeleteOutputForTestSuites ¶ added in v1.8.8
func (m *MongoRepository) DeleteOutputForTestSuites(ctx context.Context, testSuiteNames []string) error
func (*MongoRepository) DeleteOutputForTests ¶ added in v1.8.8
func (m *MongoRepository) DeleteOutputForTests(ctx context.Context, testNames []string) error
func (*MongoRepository) EndExecution ¶ added in v0.6.4
EndExecution updates execution end time
func (*MongoRepository) GetByNameAndTest ¶ added in v0.9.5
func (*MongoRepository) GetExecutionTotals ¶ added in v0.6.9
func (r *MongoRepository) GetExecutionTotals(ctx context.Context, paging bool, filter ...Filter) (totals testkube.ExecutionsTotals, err error)
func (*MongoRepository) GetExecutions ¶
func (*MongoRepository) GetLatestByTest ¶ added in v0.11.6
func (*MongoRepository) GetLatestByTests ¶ added in v0.11.8
func (*MongoRepository) GetNewestExecutions ¶
func (*MongoRepository) GetNextExecutionNumber ¶ added in v1.4.5
func (*MongoRepository) GetOutputByTest ¶ added in v1.8.8
func (*MongoRepository) GetOutputByTestSuite ¶ added in v1.8.8
func (*MongoRepository) GetTestMetrics ¶ added in v1.4.5
func (r *MongoRepository) GetTestMetrics(ctx context.Context, name string, limit, last int) (metrics testkube.ExecutionsMetrics, err error)
GetTestMetrics returns test executions metrics limited to number of executions or last N days
func (*MongoRepository) InsertOutput ¶ added in v1.8.8
func (m *MongoRepository) InsertOutput(ctx context.Context, id, testName, testSuiteName, output string) error
func (*MongoRepository) StartExecution ¶ added in v0.6.4
func (r *MongoRepository) StartExecution(ctx context.Context, id string, startTime time.Time) (err error)
StartExecution updates execution start time
func (*MongoRepository) UpdateOutput ¶ added in v1.8.8
func (m *MongoRepository) UpdateOutput(ctx context.Context, id, output string) error
func (*MongoRepository) UpdateResult ¶
func (r *MongoRepository) UpdateResult(ctx context.Context, id string, result testkube.ExecutionResult) (err error)
type OutputRepository ¶ added in v1.8.8
type OutputRepository interface { // GetOutput gets execution output by id or name GetOutput(ctx context.Context, id string) (output string, err error) // GetOutputByTest gets execution output by test name GetOutputByTest(ctx context.Context, testName string) (output string, err error) // GetOutputByTestSuite gets execution output by test suite name GetOutputByTestSuite(ctx context.Context, testSuiteName string) (output string, err error) // InsertOutput inserts new execution output InsertOutput(ctx context.Context, id, testName, testSuiteName, output string) error // UpdateOutput updates execution output UpdateOutput(ctx context.Context, id, output string) error // DeleteOutput deletes execution output DeleteOutput(ctx context.Context, id string) error // DeleteOutputByTest deletes execution output by test DeleteOutputByTest(ctx context.Context, testName string) error // DeleteOutputForTests deletes execution output for tests DeleteOutputForTests(ctx context.Context, testNames []string) error // DeleteOutputByTestSuite deletes execution output by test suite DeleteOutputByTestSuite(ctx context.Context, testSuiteName string) error // DeleteOutputForTestSuites deletes execution output for test suites DeleteOutputForTestSuites(ctx context.Context, testSuiteNames []string) error // DeleteAllOutput deletes all execution output DeleteAllOutput(ctx context.Context) error // DeleteOutputForAllTestSuite deletes all execution output for test suite DeleteOutputForAllTestSuite(ctx context.Context) error }
type Repository ¶
type Repository interface { Sequences OutputRepository // Get gets execution result by id or name Get(ctx context.Context, id string) (testkube.Execution, error) // GetByNameAndTest gets execution result by name and test name GetByNameAndTest(ctx context.Context, name, testName string) (testkube.Execution, error) // GetLatestByTest gets latest execution result by test GetLatestByTest(ctx context.Context, testName, sortField string) (testkube.Execution, error) // GetLatestByTests gets latest execution results by test names GetLatestByTests(ctx context.Context, testNames []string, sortField string) (executions []testkube.Execution, err error) // GetExecutions gets executions using a filter, use filter with no data for all GetExecutions(ctx context.Context, filter Filter) ([]testkube.Execution, error) // GetExecutionTotals gets the statistics on number of executions using a filter, but without paging GetExecutionTotals(ctx context.Context, paging bool, filter ...Filter) (result testkube.ExecutionsTotals, err error) // Insert inserts new execution result Insert(ctx context.Context, result testkube.Execution) error // Update updates execution result Update(ctx context.Context, result testkube.Execution) error // UpdateExecution updates result in execution UpdateResult(ctx context.Context, id string, execution testkube.ExecutionResult) error // StartExecution updates execution start time StartExecution(ctx context.Context, id string, startTime time.Time) error // EndExecution updates execution end time EndExecution(ctx context.Context, execution testkube.Execution) error // GetLabels get all available labels GetLabels(ctx context.Context) (labels map[string][]string, err error) // DeleteByTest deletes execution results by test DeleteByTest(ctx context.Context, testName string) error // DeleteByTestSuite deletes execution results by test suite DeleteByTestSuite(ctx context.Context, testSuiteName string) error // DeleteAll deletes all execution results DeleteAll(ctx context.Context) error // DeleteByTests deletes execution results by tests DeleteByTests(ctx context.Context, testNames []string) (err error) // DeleteByTestSuites deletes execution results by test suites DeleteByTestSuites(ctx context.Context, testSuiteNames []string) (err error) // DeleteForAllTestSuites deletes execution results for all test suites DeleteForAllTestSuites(ctx context.Context) (err error) GetTestMetrics(ctx context.Context, name string, limit, last int) (metrics testkube.ExecutionsMetrics, err error) }