Documentation
¶
Index ¶
- type StorageContractSuite
- func (s *StorageContractSuite) SetContext(ctx context.Context)
- func (s *StorageContractSuite) SetLogger(log *testutil.TestLogger)
- func (s *StorageContractSuite) SetStorage(store storage.Storage)
- func (s *StorageContractSuite) TestStorage_CreateAndGet()
- func (s *StorageContractSuite) TestStorage_CreateAndGet_StackedPRs()
- func (s *StorageContractSuite) TestStorage_CreateDuplicate()
- func (s *StorageContractSuite) TestStorage_NotFound()
- func (s *StorageContractSuite) TestStorage_OptimisticLocking()
- func (s *StorageContractSuite) TestStorage_UpdateState()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type StorageContractSuite ¶
StorageContractSuite defines the contract tests for the storage.Storage interface. All storage implementations must pass these tests. Implementation-specific tests should embed this suite and call SetStorage().
func (*StorageContractSuite) SetContext ¶
func (s *StorageContractSuite) SetContext(ctx context.Context)
SetContext sets the context for tests
func (*StorageContractSuite) SetLogger ¶
func (s *StorageContractSuite) SetLogger(log *testutil.TestLogger)
SetLogger sets the logger for tests
func (*StorageContractSuite) SetStorage ¶
func (s *StorageContractSuite) SetStorage(store storage.Storage)
SetStorage is called by implementation tests to provide the concrete storage instance
func (*StorageContractSuite) TestStorage_CreateAndGet ¶
func (s *StorageContractSuite) TestStorage_CreateAndGet()
TestStorage_CreateAndGet tests creating and retrieving a request
func (*StorageContractSuite) TestStorage_CreateAndGet_StackedPRs ¶
func (s *StorageContractSuite) TestStorage_CreateAndGet_StackedPRs()
TestStorage_CreateAndGet_StackedPRs tests creating and retrieving a request with stacked PRs
func (*StorageContractSuite) TestStorage_CreateDuplicate ¶
func (s *StorageContractSuite) TestStorage_CreateDuplicate()
TestStorage_CreateDuplicate tests creating a request with duplicate ID
func (*StorageContractSuite) TestStorage_NotFound ¶
func (s *StorageContractSuite) TestStorage_NotFound()
TestStorage_NotFound tests getting a non-existent request
func (*StorageContractSuite) TestStorage_OptimisticLocking ¶
func (s *StorageContractSuite) TestStorage_OptimisticLocking()
TestStorage_OptimisticLocking tests version-based optimistic locking
func (*StorageContractSuite) TestStorage_UpdateState ¶
func (s *StorageContractSuite) TestStorage_UpdateState()
TestStorage_UpdateState tests updating request state