Documentation
¶
Overview ¶
Package mocks provides generated mock implementations for testing.
Index ¶
- type DriverMock
- func (mmExecute *DriverMock) Execute(ctx context.Context, predicates []predicate.Predicate, ...) (r1 tx.Response, err error)
- func (mmExecute *DriverMock) ExecuteAfterCounter() uint64
- func (mmExecute *DriverMock) ExecuteBeforeCounter() uint64
- func (m *DriverMock) MinimockExecuteDone() bool
- func (m *DriverMock) MinimockExecuteInspect()
- func (m *DriverMock) MinimockFinish()
- func (m *DriverMock) MinimockNewLockerDone() bool
- func (m *DriverMock) MinimockNewLockerInspect()
- func (m *DriverMock) MinimockWait(timeout mm_time.Duration)
- func (m *DriverMock) MinimockWatchDone() bool
- func (m *DriverMock) MinimockWatchInspect()
- func (mmNewLocker *DriverMock) NewLocker(ctx context.Context, name string, opts ...locker.Option) (l1 locker.Locker, err error)
- func (mmNewLocker *DriverMock) NewLockerAfterCounter() uint64
- func (mmNewLocker *DriverMock) NewLockerBeforeCounter() uint64
- func (mmWatch *DriverMock) Watch(ctx context.Context, key []byte) (ch1 <-chan watch.Event, f1 func(), err error)
- func (mmWatch *DriverMock) WatchAfterCounter() uint64
- func (mmWatch *DriverMock) WatchBeforeCounter() uint64
- type DriverMockExecuteExpectation
- type DriverMockExecuteExpectationOrigins
- type DriverMockExecuteParamPtrs
- type DriverMockExecuteParams
- type DriverMockExecuteResults
- type DriverMockNewLockerExpectation
- type DriverMockNewLockerExpectationOrigins
- type DriverMockNewLockerParamPtrs
- type DriverMockNewLockerParams
- type DriverMockNewLockerResults
- type DriverMockWatchExpectation
- type DriverMockWatchExpectationOrigins
- type DriverMockWatchParamPtrs
- type DriverMockWatchParams
- type DriverMockWatchResults
- type ETCDTxnMock
- func (mmCommit *ETCDTxnMock) Commit() (tp1 *mm_clientv3.TxnResponse, err error)
- func (mmCommit *ETCDTxnMock) CommitAfterCounter() uint64
- func (mmCommit *ETCDTxnMock) CommitBeforeCounter() uint64
- func (mmElse *ETCDTxnMock) Else(ops ...mm_clientv3.Op) (t1 mm_clientv3.Txn)
- func (mmElse *ETCDTxnMock) ElseAfterCounter() uint64
- func (mmElse *ETCDTxnMock) ElseBeforeCounter() uint64
- func (mmIf *ETCDTxnMock) If(cs ...mm_clientv3.Cmp) (t1 mm_clientv3.Txn)
- func (mmIf *ETCDTxnMock) IfAfterCounter() uint64
- func (mmIf *ETCDTxnMock) IfBeforeCounter() uint64
- func (m *ETCDTxnMock) MinimockCommitDone() bool
- func (m *ETCDTxnMock) MinimockCommitInspect()
- func (m *ETCDTxnMock) MinimockElseDone() bool
- func (m *ETCDTxnMock) MinimockElseInspect()
- func (m *ETCDTxnMock) MinimockFinish()
- func (m *ETCDTxnMock) MinimockIfDone() bool
- func (m *ETCDTxnMock) MinimockIfInspect()
- func (m *ETCDTxnMock) MinimockThenDone() bool
- func (m *ETCDTxnMock) MinimockThenInspect()
- func (m *ETCDTxnMock) MinimockWait(timeout mm_time.Duration)
- func (mmThen *ETCDTxnMock) Then(ops ...mm_clientv3.Op) (t1 mm_clientv3.Txn)
- func (mmThen *ETCDTxnMock) ThenAfterCounter() uint64
- func (mmThen *ETCDTxnMock) ThenBeforeCounter() uint64
- type ETCDTxnMockCommitExpectation
- type ETCDTxnMockCommitResults
- type ETCDTxnMockElseExpectation
- type ETCDTxnMockElseExpectationOrigins
- type ETCDTxnMockElseParamPtrs
- type ETCDTxnMockElseParams
- type ETCDTxnMockElseResults
- type ETCDTxnMockIfExpectation
- type ETCDTxnMockIfExpectationOrigins
- type ETCDTxnMockIfParamPtrs
- type ETCDTxnMockIfParams
- type ETCDTxnMockIfResults
- type ETCDTxnMockThenExpectation
- type ETCDTxnMockThenExpectationOrigins
- type ETCDTxnMockThenParamPtrs
- type ETCDTxnMockThenParams
- type ETCDTxnMockThenResults
- type EtcdClientMock
- func (m *EtcdClientMock) MinimockFinish()
- func (m *EtcdClientMock) MinimockTxnDone() bool
- func (m *EtcdClientMock) MinimockTxnInspect()
- func (m *EtcdClientMock) MinimockWait(timeout mm_time.Duration)
- func (m *EtcdClientMock) MinimockWatchDone() bool
- func (m *EtcdClientMock) MinimockWatchInspect()
- func (mmTxn *EtcdClientMock) Txn(ctx context.Context) (t1 etcd.Txn)
- func (mmTxn *EtcdClientMock) TxnAfterCounter() uint64
- func (mmTxn *EtcdClientMock) TxnBeforeCounter() uint64
- func (mmWatch *EtcdClientMock) Watch(ctx context.Context, key string, opts ...etcd.OpOption) (w1 etcd.WatchChan)
- func (mmWatch *EtcdClientMock) WatchAfterCounter() uint64
- func (mmWatch *EtcdClientMock) WatchBeforeCounter() uint64
- type EtcdClientMockTxnExpectation
- type EtcdClientMockTxnExpectationOrigins
- type EtcdClientMockTxnParamPtrs
- type EtcdClientMockTxnParams
- type EtcdClientMockTxnResults
- type EtcdClientMockWatchExpectation
- type EtcdClientMockWatchExpectationOrigins
- type EtcdClientMockWatchParamPtrs
- type EtcdClientMockWatchParams
- type EtcdClientMockWatchResults
- type LockerMock
- func (mmDone *LockerMock) Done() (ch1 ...)
- func (mmDone *LockerMock) DoneAfterCounter() uint64
- func (mmDone *LockerMock) DoneBeforeCounter() uint64
- func (mmKey *LockerMock) Key() (s1 string)
- func (mmKey *LockerMock) KeyAfterCounter() uint64
- func (mmKey *LockerMock) KeyBeforeCounter() uint64
- func (mmLock *LockerMock) Lock(ctx context.Context) (err error)
- func (mmLock *LockerMock) LockAfterCounter() uint64
- func (mmLock *LockerMock) LockBeforeCounter() uint64
- func (m *LockerMock) MinimockDoneDone() bool
- func (m *LockerMock) MinimockDoneInspect()
- func (m *LockerMock) MinimockFinish()
- func (m *LockerMock) MinimockKeyDone() bool
- func (m *LockerMock) MinimockKeyInspect()
- func (m *LockerMock) MinimockLockDone() bool
- func (m *LockerMock) MinimockLockInspect()
- func (m *LockerMock) MinimockTryLockDone() bool
- func (m *LockerMock) MinimockTryLockInspect()
- func (m *LockerMock) MinimockUnlockDone() bool
- func (m *LockerMock) MinimockUnlockInspect()
- func (m *LockerMock) MinimockWait(timeout mm_time.Duration)
- func (mmTryLock *LockerMock) TryLock(ctx context.Context) (err error)
- func (mmTryLock *LockerMock) TryLockAfterCounter() uint64
- func (mmTryLock *LockerMock) TryLockBeforeCounter() uint64
- func (mmUnlock *LockerMock) Unlock(ctx context.Context) (err error)
- func (mmUnlock *LockerMock) UnlockAfterCounter() uint64
- func (mmUnlock *LockerMock) UnlockBeforeCounter() uint64
- type LockerMockDoneExpectation
- type LockerMockDoneResults
- type LockerMockKeyExpectation
- type LockerMockKeyResults
- type LockerMockLockExpectation
- type LockerMockLockExpectationOrigins
- type LockerMockLockParamPtrs
- type LockerMockLockParams
- type LockerMockLockResults
- type LockerMockTryLockExpectation
- type LockerMockTryLockExpectationOrigins
- type LockerMockTryLockParamPtrs
- type LockerMockTryLockParams
- type LockerMockTryLockResults
- type LockerMockUnlockExpectation
- type LockerMockUnlockExpectationOrigins
- type LockerMockUnlockParamPtrs
- type LockerMockUnlockParams
- type LockerMockUnlockResults
- type TCSClientMock
- func (mmDo *TCSClientMock) Do(req tarantool.Request) (fut tarantool.Future)
- func (mmDo *TCSClientMock) DoAfterCounter() uint64
- func (mmDo *TCSClientMock) DoBeforeCounter() uint64
- func (m *TCSClientMock) MinimockDoDone() bool
- func (m *TCSClientMock) MinimockDoInspect()
- func (m *TCSClientMock) MinimockFinish()
- func (m *TCSClientMock) MinimockNewWatcherDone() bool
- func (m *TCSClientMock) MinimockNewWatcherInspect()
- func (m *TCSClientMock) MinimockWait(timeout mm_time.Duration)
- func (mmNewWatcher *TCSClientMock) NewWatcher(key string, callback tarantool.WatchCallback) (w1 tarantool.Watcher, err error)
- func (mmNewWatcher *TCSClientMock) NewWatcherAfterCounter() uint64
- func (mmNewWatcher *TCSClientMock) NewWatcherBeforeCounter() uint64
- type TCSClientMockDoExpectation
- type TCSClientMockDoExpectationOrigins
- type TCSClientMockDoParamPtrs
- type TCSClientMockDoParams
- type TCSClientMockDoResults
- type TCSClientMockNewWatcherExpectation
- type TCSClientMockNewWatcherExpectationOrigins
- type TCSClientMockNewWatcherParamPtrs
- type TCSClientMockNewWatcherParams
- type TCSClientMockNewWatcherResults
- type WatcherMock
- func (m *WatcherMock) MinimockFinish()
- func (m *WatcherMock) MinimockUnregisterDone() bool
- func (m *WatcherMock) MinimockUnregisterInspect()
- func (m *WatcherMock) MinimockWait(timeout mm_time.Duration)
- func (mmUnregister *WatcherMock) Unregister()
- func (mmUnregister *WatcherMock) UnregisterAfterCounter() uint64
- func (mmUnregister *WatcherMock) UnregisterBeforeCounter() uint64
- type WatcherMockUnregisterExpectation
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DriverMock ¶
type DriverMock struct {
ExecuteMock mDriverMockExecute
NewLockerMock mDriverMockNewLocker
WatchMock mDriverMockWatch
// contains filtered or unexported fields
}
DriverMock implements mm_driver.Driver
func NewDriverMock ¶
func NewDriverMock(t minimock.Tester) *DriverMock
NewDriverMock returns a mock for mm_driver.Driver
func (*DriverMock) Execute ¶
func (mmExecute *DriverMock) Execute(ctx context.Context, predicates []predicate.Predicate, thenOps []operation.Operation, elseOps []operation.Operation) (r1 tx.Response, err error)
Execute implements mm_driver.Driver
func (*DriverMock) ExecuteAfterCounter ¶
func (mmExecute *DriverMock) ExecuteAfterCounter() uint64
ExecuteAfterCounter returns a count of finished DriverMock.Execute invocations
func (*DriverMock) ExecuteBeforeCounter ¶
func (mmExecute *DriverMock) ExecuteBeforeCounter() uint64
ExecuteBeforeCounter returns a count of DriverMock.Execute invocations
func (*DriverMock) MinimockExecuteDone ¶
func (m *DriverMock) MinimockExecuteDone() bool
MinimockExecuteDone returns true if the count of the Execute invocations corresponds the number of defined expectations
func (*DriverMock) MinimockExecuteInspect ¶
func (m *DriverMock) MinimockExecuteInspect()
MinimockExecuteInspect logs each unmet expectation
func (*DriverMock) MinimockFinish ¶
func (m *DriverMock) MinimockFinish()
MinimockFinish checks that all mocked methods have been called the expected number of times
func (*DriverMock) MinimockNewLockerDone ¶
func (m *DriverMock) MinimockNewLockerDone() bool
MinimockNewLockerDone returns true if the count of the NewLocker invocations corresponds the number of defined expectations
func (*DriverMock) MinimockNewLockerInspect ¶
func (m *DriverMock) MinimockNewLockerInspect()
MinimockNewLockerInspect logs each unmet expectation
func (*DriverMock) MinimockWait ¶
func (m *DriverMock) MinimockWait(timeout mm_time.Duration)
MinimockWait waits for all mocked methods to be called the expected number of times
func (*DriverMock) MinimockWatchDone ¶
func (m *DriverMock) MinimockWatchDone() bool
MinimockWatchDone returns true if the count of the Watch invocations corresponds the number of defined expectations
func (*DriverMock) MinimockWatchInspect ¶
func (m *DriverMock) MinimockWatchInspect()
MinimockWatchInspect logs each unmet expectation
func (*DriverMock) NewLocker ¶
func (mmNewLocker *DriverMock) NewLocker(ctx context.Context, name string, opts ...locker.Option) (l1 locker.Locker, err error)
NewLocker implements mm_driver.Driver
func (*DriverMock) NewLockerAfterCounter ¶
func (mmNewLocker *DriverMock) NewLockerAfterCounter() uint64
NewLockerAfterCounter returns a count of finished DriverMock.NewLocker invocations
func (*DriverMock) NewLockerBeforeCounter ¶
func (mmNewLocker *DriverMock) NewLockerBeforeCounter() uint64
NewLockerBeforeCounter returns a count of DriverMock.NewLocker invocations
func (*DriverMock) Watch ¶
func (mmWatch *DriverMock) Watch(ctx context.Context, key []byte) (ch1 <-chan watch.Event, f1 func(), err error)
Watch implements mm_driver.Driver
func (*DriverMock) WatchAfterCounter ¶
func (mmWatch *DriverMock) WatchAfterCounter() uint64
WatchAfterCounter returns a count of finished DriverMock.Watch invocations
func (*DriverMock) WatchBeforeCounter ¶
func (mmWatch *DriverMock) WatchBeforeCounter() uint64
WatchBeforeCounter returns a count of DriverMock.Watch invocations
type DriverMockExecuteExpectation ¶
type DriverMockExecuteExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
DriverMockExecuteExpectation specifies expectation struct of the Driver.Execute
func (*DriverMockExecuteExpectation) Then ¶
func (e *DriverMockExecuteExpectation) Then(r1 tx.Response, err error) *DriverMock
Then sets up Driver.Execute return parameters for the expectation previously defined by the When method
type DriverMockExecuteExpectationOrigins ¶
type DriverMockExecuteExpectationOrigins struct {
// contains filtered or unexported fields
}
DriverMockExecuteOrigins contains origins of expectations of the Driver.Execute
type DriverMockExecuteParamPtrs ¶
type DriverMockExecuteParamPtrs struct {
// contains filtered or unexported fields
}
DriverMockExecuteParamPtrs contains pointers to parameters of the Driver.Execute
type DriverMockExecuteParams ¶
type DriverMockExecuteParams struct {
// contains filtered or unexported fields
}
DriverMockExecuteParams contains parameters of the Driver.Execute
type DriverMockExecuteResults ¶
type DriverMockExecuteResults struct {
// contains filtered or unexported fields
}
DriverMockExecuteResults contains results of the Driver.Execute
type DriverMockNewLockerExpectation ¶
type DriverMockNewLockerExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
DriverMockNewLockerExpectation specifies expectation struct of the Driver.NewLocker
func (*DriverMockNewLockerExpectation) Then ¶
func (e *DriverMockNewLockerExpectation) Then(l1 locker.Locker, err error) *DriverMock
Then sets up Driver.NewLocker return parameters for the expectation previously defined by the When method
type DriverMockNewLockerExpectationOrigins ¶
type DriverMockNewLockerExpectationOrigins struct {
// contains filtered or unexported fields
}
DriverMockNewLockerOrigins contains origins of expectations of the Driver.NewLocker
type DriverMockNewLockerParamPtrs ¶
type DriverMockNewLockerParamPtrs struct {
// contains filtered or unexported fields
}
DriverMockNewLockerParamPtrs contains pointers to parameters of the Driver.NewLocker
type DriverMockNewLockerParams ¶
type DriverMockNewLockerParams struct {
// contains filtered or unexported fields
}
DriverMockNewLockerParams contains parameters of the Driver.NewLocker
type DriverMockNewLockerResults ¶
type DriverMockNewLockerResults struct {
// contains filtered or unexported fields
}
DriverMockNewLockerResults contains results of the Driver.NewLocker
type DriverMockWatchExpectation ¶
type DriverMockWatchExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
DriverMockWatchExpectation specifies expectation struct of the Driver.Watch
func (*DriverMockWatchExpectation) Then ¶
func (e *DriverMockWatchExpectation) Then(ch1 <-chan watch.Event, f1 func(), err error) *DriverMock
Then sets up Driver.Watch return parameters for the expectation previously defined by the When method
type DriverMockWatchExpectationOrigins ¶
type DriverMockWatchExpectationOrigins struct {
// contains filtered or unexported fields
}
DriverMockWatchOrigins contains origins of expectations of the Driver.Watch
type DriverMockWatchParamPtrs ¶
type DriverMockWatchParamPtrs struct {
// contains filtered or unexported fields
}
DriverMockWatchParamPtrs contains pointers to parameters of the Driver.Watch
type DriverMockWatchParams ¶
type DriverMockWatchParams struct {
// contains filtered or unexported fields
}
DriverMockWatchParams contains parameters of the Driver.Watch
type DriverMockWatchResults ¶
type DriverMockWatchResults struct {
// contains filtered or unexported fields
}
DriverMockWatchResults contains results of the Driver.Watch
type ETCDTxnMock ¶
type ETCDTxnMock struct {
CommitMock mETCDTxnMockCommit
ElseMock mETCDTxnMockElse
IfMock mETCDTxnMockIf
ThenMock mETCDTxnMockThen
// contains filtered or unexported fields
}
ETCDTxnMock implements mm_clientv3.Txn
func NewETCDTxnMock ¶
func NewETCDTxnMock(t minimock.Tester) *ETCDTxnMock
NewETCDTxnMock returns a mock for mm_clientv3.Txn
func (*ETCDTxnMock) Commit ¶
func (mmCommit *ETCDTxnMock) Commit() (tp1 *mm_clientv3.TxnResponse, err error)
Commit implements mm_clientv3.Txn
func (*ETCDTxnMock) CommitAfterCounter ¶
func (mmCommit *ETCDTxnMock) CommitAfterCounter() uint64
CommitAfterCounter returns a count of finished ETCDTxnMock.Commit invocations
func (*ETCDTxnMock) CommitBeforeCounter ¶
func (mmCommit *ETCDTxnMock) CommitBeforeCounter() uint64
CommitBeforeCounter returns a count of ETCDTxnMock.Commit invocations
func (*ETCDTxnMock) Else ¶
func (mmElse *ETCDTxnMock) Else(ops ...mm_clientv3.Op) (t1 mm_clientv3.Txn)
Else implements mm_clientv3.Txn
func (*ETCDTxnMock) ElseAfterCounter ¶
func (mmElse *ETCDTxnMock) ElseAfterCounter() uint64
ElseAfterCounter returns a count of finished ETCDTxnMock.Else invocations
func (*ETCDTxnMock) ElseBeforeCounter ¶
func (mmElse *ETCDTxnMock) ElseBeforeCounter() uint64
ElseBeforeCounter returns a count of ETCDTxnMock.Else invocations
func (*ETCDTxnMock) If ¶
func (mmIf *ETCDTxnMock) If(cs ...mm_clientv3.Cmp) (t1 mm_clientv3.Txn)
If implements mm_clientv3.Txn
func (*ETCDTxnMock) IfAfterCounter ¶
func (mmIf *ETCDTxnMock) IfAfterCounter() uint64
IfAfterCounter returns a count of finished ETCDTxnMock.If invocations
func (*ETCDTxnMock) IfBeforeCounter ¶
func (mmIf *ETCDTxnMock) IfBeforeCounter() uint64
IfBeforeCounter returns a count of ETCDTxnMock.If invocations
func (*ETCDTxnMock) MinimockCommitDone ¶
func (m *ETCDTxnMock) MinimockCommitDone() bool
MinimockCommitDone returns true if the count of the Commit invocations corresponds the number of defined expectations
func (*ETCDTxnMock) MinimockCommitInspect ¶
func (m *ETCDTxnMock) MinimockCommitInspect()
MinimockCommitInspect logs each unmet expectation
func (*ETCDTxnMock) MinimockElseDone ¶
func (m *ETCDTxnMock) MinimockElseDone() bool
MinimockElseDone returns true if the count of the Else invocations corresponds the number of defined expectations
func (*ETCDTxnMock) MinimockElseInspect ¶
func (m *ETCDTxnMock) MinimockElseInspect()
MinimockElseInspect logs each unmet expectation
func (*ETCDTxnMock) MinimockFinish ¶
func (m *ETCDTxnMock) MinimockFinish()
MinimockFinish checks that all mocked methods have been called the expected number of times
func (*ETCDTxnMock) MinimockIfDone ¶
func (m *ETCDTxnMock) MinimockIfDone() bool
MinimockIfDone returns true if the count of the If invocations corresponds the number of defined expectations
func (*ETCDTxnMock) MinimockIfInspect ¶
func (m *ETCDTxnMock) MinimockIfInspect()
MinimockIfInspect logs each unmet expectation
func (*ETCDTxnMock) MinimockThenDone ¶
func (m *ETCDTxnMock) MinimockThenDone() bool
MinimockThenDone returns true if the count of the Then invocations corresponds the number of defined expectations
func (*ETCDTxnMock) MinimockThenInspect ¶
func (m *ETCDTxnMock) MinimockThenInspect()
MinimockThenInspect logs each unmet expectation
func (*ETCDTxnMock) MinimockWait ¶
func (m *ETCDTxnMock) MinimockWait(timeout mm_time.Duration)
MinimockWait waits for all mocked methods to be called the expected number of times
func (*ETCDTxnMock) Then ¶
func (mmThen *ETCDTxnMock) Then(ops ...mm_clientv3.Op) (t1 mm_clientv3.Txn)
Then implements mm_clientv3.Txn
func (*ETCDTxnMock) ThenAfterCounter ¶
func (mmThen *ETCDTxnMock) ThenAfterCounter() uint64
ThenAfterCounter returns a count of finished ETCDTxnMock.Then invocations
func (*ETCDTxnMock) ThenBeforeCounter ¶
func (mmThen *ETCDTxnMock) ThenBeforeCounter() uint64
ThenBeforeCounter returns a count of ETCDTxnMock.Then invocations
type ETCDTxnMockCommitExpectation ¶
type ETCDTxnMockCommitExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
ETCDTxnMockCommitExpectation specifies expectation struct of the Txn.Commit
type ETCDTxnMockCommitResults ¶
type ETCDTxnMockCommitResults struct {
// contains filtered or unexported fields
}
ETCDTxnMockCommitResults contains results of the Txn.Commit
type ETCDTxnMockElseExpectation ¶
type ETCDTxnMockElseExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
ETCDTxnMockElseExpectation specifies expectation struct of the Txn.Else
func (*ETCDTxnMockElseExpectation) Then ¶
func (e *ETCDTxnMockElseExpectation) Then(t1 mm_clientv3.Txn) *ETCDTxnMock
Then sets up Txn.Else return parameters for the expectation previously defined by the When method
type ETCDTxnMockElseExpectationOrigins ¶
type ETCDTxnMockElseExpectationOrigins struct {
// contains filtered or unexported fields
}
ETCDTxnMockElseOrigins contains origins of expectations of the Txn.Else
type ETCDTxnMockElseParamPtrs ¶
type ETCDTxnMockElseParamPtrs struct {
// contains filtered or unexported fields
}
ETCDTxnMockElseParamPtrs contains pointers to parameters of the Txn.Else
type ETCDTxnMockElseParams ¶
type ETCDTxnMockElseParams struct {
// contains filtered or unexported fields
}
ETCDTxnMockElseParams contains parameters of the Txn.Else
type ETCDTxnMockElseResults ¶
type ETCDTxnMockElseResults struct {
// contains filtered or unexported fields
}
ETCDTxnMockElseResults contains results of the Txn.Else
type ETCDTxnMockIfExpectation ¶
type ETCDTxnMockIfExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
ETCDTxnMockIfExpectation specifies expectation struct of the Txn.If
func (*ETCDTxnMockIfExpectation) Then ¶
func (e *ETCDTxnMockIfExpectation) Then(t1 mm_clientv3.Txn) *ETCDTxnMock
Then sets up Txn.If return parameters for the expectation previously defined by the When method
type ETCDTxnMockIfExpectationOrigins ¶
type ETCDTxnMockIfExpectationOrigins struct {
// contains filtered or unexported fields
}
ETCDTxnMockIfOrigins contains origins of expectations of the Txn.If
type ETCDTxnMockIfParamPtrs ¶
type ETCDTxnMockIfParamPtrs struct {
// contains filtered or unexported fields
}
ETCDTxnMockIfParamPtrs contains pointers to parameters of the Txn.If
type ETCDTxnMockIfParams ¶
type ETCDTxnMockIfParams struct {
// contains filtered or unexported fields
}
ETCDTxnMockIfParams contains parameters of the Txn.If
type ETCDTxnMockIfResults ¶
type ETCDTxnMockIfResults struct {
// contains filtered or unexported fields
}
ETCDTxnMockIfResults contains results of the Txn.If
type ETCDTxnMockThenExpectation ¶
type ETCDTxnMockThenExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
ETCDTxnMockThenExpectation specifies expectation struct of the Txn.Then
func (*ETCDTxnMockThenExpectation) Then ¶
func (e *ETCDTxnMockThenExpectation) Then(t1 mm_clientv3.Txn) *ETCDTxnMock
Then sets up Txn.Then return parameters for the expectation previously defined by the When method
type ETCDTxnMockThenExpectationOrigins ¶
type ETCDTxnMockThenExpectationOrigins struct {
// contains filtered or unexported fields
}
ETCDTxnMockThenOrigins contains origins of expectations of the Txn.Then
type ETCDTxnMockThenParamPtrs ¶
type ETCDTxnMockThenParamPtrs struct {
// contains filtered or unexported fields
}
ETCDTxnMockThenParamPtrs contains pointers to parameters of the Txn.Then
type ETCDTxnMockThenParams ¶
type ETCDTxnMockThenParams struct {
// contains filtered or unexported fields
}
ETCDTxnMockThenParams contains parameters of the Txn.Then
type ETCDTxnMockThenResults ¶
type ETCDTxnMockThenResults struct {
// contains filtered or unexported fields
}
ETCDTxnMockThenResults contains results of the Txn.Then
type EtcdClientMock ¶
type EtcdClientMock struct {
TxnMock mEtcdClientMockTxn
WatchMock mEtcdClientMockWatch
// contains filtered or unexported fields
}
EtcdClientMock implements mm_etcd.Client
func NewEtcdClientMock ¶
func NewEtcdClientMock(t minimock.Tester) *EtcdClientMock
NewEtcdClientMock returns a mock for mm_etcd.Client
func (*EtcdClientMock) MinimockFinish ¶
func (m *EtcdClientMock) MinimockFinish()
MinimockFinish checks that all mocked methods have been called the expected number of times
func (*EtcdClientMock) MinimockTxnDone ¶
func (m *EtcdClientMock) MinimockTxnDone() bool
MinimockTxnDone returns true if the count of the Txn invocations corresponds the number of defined expectations
func (*EtcdClientMock) MinimockTxnInspect ¶
func (m *EtcdClientMock) MinimockTxnInspect()
MinimockTxnInspect logs each unmet expectation
func (*EtcdClientMock) MinimockWait ¶
func (m *EtcdClientMock) MinimockWait(timeout mm_time.Duration)
MinimockWait waits for all mocked methods to be called the expected number of times
func (*EtcdClientMock) MinimockWatchDone ¶
func (m *EtcdClientMock) MinimockWatchDone() bool
MinimockWatchDone returns true if the count of the Watch invocations corresponds the number of defined expectations
func (*EtcdClientMock) MinimockWatchInspect ¶
func (m *EtcdClientMock) MinimockWatchInspect()
MinimockWatchInspect logs each unmet expectation
func (*EtcdClientMock) Txn ¶
func (mmTxn *EtcdClientMock) Txn(ctx context.Context) (t1 etcd.Txn)
Txn implements mm_etcd.Client
func (*EtcdClientMock) TxnAfterCounter ¶
func (mmTxn *EtcdClientMock) TxnAfterCounter() uint64
TxnAfterCounter returns a count of finished EtcdClientMock.Txn invocations
func (*EtcdClientMock) TxnBeforeCounter ¶
func (mmTxn *EtcdClientMock) TxnBeforeCounter() uint64
TxnBeforeCounter returns a count of EtcdClientMock.Txn invocations
func (*EtcdClientMock) Watch ¶
func (mmWatch *EtcdClientMock) Watch(ctx context.Context, key string, opts ...etcd.OpOption) (w1 etcd.WatchChan)
Watch implements mm_etcd.Client
func (*EtcdClientMock) WatchAfterCounter ¶
func (mmWatch *EtcdClientMock) WatchAfterCounter() uint64
WatchAfterCounter returns a count of finished EtcdClientMock.Watch invocations
func (*EtcdClientMock) WatchBeforeCounter ¶
func (mmWatch *EtcdClientMock) WatchBeforeCounter() uint64
WatchBeforeCounter returns a count of EtcdClientMock.Watch invocations
type EtcdClientMockTxnExpectation ¶
type EtcdClientMockTxnExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
EtcdClientMockTxnExpectation specifies expectation struct of the Client.Txn
func (*EtcdClientMockTxnExpectation) Then ¶
func (e *EtcdClientMockTxnExpectation) Then(t1 etcd.Txn) *EtcdClientMock
Then sets up Client.Txn return parameters for the expectation previously defined by the When method
type EtcdClientMockTxnExpectationOrigins ¶
type EtcdClientMockTxnExpectationOrigins struct {
// contains filtered or unexported fields
}
EtcdClientMockTxnOrigins contains origins of expectations of the Client.Txn
type EtcdClientMockTxnParamPtrs ¶
type EtcdClientMockTxnParamPtrs struct {
// contains filtered or unexported fields
}
EtcdClientMockTxnParamPtrs contains pointers to parameters of the Client.Txn
type EtcdClientMockTxnParams ¶
type EtcdClientMockTxnParams struct {
// contains filtered or unexported fields
}
EtcdClientMockTxnParams contains parameters of the Client.Txn
type EtcdClientMockTxnResults ¶
type EtcdClientMockTxnResults struct {
// contains filtered or unexported fields
}
EtcdClientMockTxnResults contains results of the Client.Txn
type EtcdClientMockWatchExpectation ¶
type EtcdClientMockWatchExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
EtcdClientMockWatchExpectation specifies expectation struct of the Client.Watch
func (*EtcdClientMockWatchExpectation) Then ¶
func (e *EtcdClientMockWatchExpectation) Then(w1 etcd.WatchChan) *EtcdClientMock
Then sets up Client.Watch return parameters for the expectation previously defined by the When method
type EtcdClientMockWatchExpectationOrigins ¶
type EtcdClientMockWatchExpectationOrigins struct {
// contains filtered or unexported fields
}
EtcdClientMockWatchOrigins contains origins of expectations of the Client.Watch
type EtcdClientMockWatchParamPtrs ¶
type EtcdClientMockWatchParamPtrs struct {
// contains filtered or unexported fields
}
EtcdClientMockWatchParamPtrs contains pointers to parameters of the Client.Watch
type EtcdClientMockWatchParams ¶
type EtcdClientMockWatchParams struct {
// contains filtered or unexported fields
}
EtcdClientMockWatchParams contains parameters of the Client.Watch
type EtcdClientMockWatchResults ¶
type EtcdClientMockWatchResults struct {
// contains filtered or unexported fields
}
EtcdClientMockWatchResults contains results of the Client.Watch
type LockerMock ¶
type LockerMock struct {
DoneMock mLockerMockDone
KeyMock mLockerMockKey
LockMock mLockerMockLock
TryLockMock mLockerMockTryLock
UnlockMock mLockerMockUnlock
// contains filtered or unexported fields
}
LockerMock implements mm_locker.Locker
func NewLockerMock ¶
func NewLockerMock(t minimock.Tester) *LockerMock
NewLockerMock returns a mock for mm_locker.Locker
func (*LockerMock) Done ¶
func (mmDone *LockerMock) Done() (ch1 <-chan struct { })
Done implements mm_locker.Locker
func (*LockerMock) DoneAfterCounter ¶
func (mmDone *LockerMock) DoneAfterCounter() uint64
DoneAfterCounter returns a count of finished LockerMock.Done invocations
func (*LockerMock) DoneBeforeCounter ¶
func (mmDone *LockerMock) DoneBeforeCounter() uint64
DoneBeforeCounter returns a count of LockerMock.Done invocations
func (*LockerMock) KeyAfterCounter ¶
func (mmKey *LockerMock) KeyAfterCounter() uint64
KeyAfterCounter returns a count of finished LockerMock.Key invocations
func (*LockerMock) KeyBeforeCounter ¶
func (mmKey *LockerMock) KeyBeforeCounter() uint64
KeyBeforeCounter returns a count of LockerMock.Key invocations
func (*LockerMock) Lock ¶
func (mmLock *LockerMock) Lock(ctx context.Context) (err error)
Lock implements mm_locker.Locker
func (*LockerMock) LockAfterCounter ¶
func (mmLock *LockerMock) LockAfterCounter() uint64
LockAfterCounter returns a count of finished LockerMock.Lock invocations
func (*LockerMock) LockBeforeCounter ¶
func (mmLock *LockerMock) LockBeforeCounter() uint64
LockBeforeCounter returns a count of LockerMock.Lock invocations
func (*LockerMock) MinimockDoneDone ¶
func (m *LockerMock) MinimockDoneDone() bool
MinimockDoneDone returns true if the count of the Done invocations corresponds the number of defined expectations
func (*LockerMock) MinimockDoneInspect ¶
func (m *LockerMock) MinimockDoneInspect()
MinimockDoneInspect logs each unmet expectation
func (*LockerMock) MinimockFinish ¶
func (m *LockerMock) MinimockFinish()
MinimockFinish checks that all mocked methods have been called the expected number of times
func (*LockerMock) MinimockKeyDone ¶
func (m *LockerMock) MinimockKeyDone() bool
MinimockKeyDone returns true if the count of the Key invocations corresponds the number of defined expectations
func (*LockerMock) MinimockKeyInspect ¶
func (m *LockerMock) MinimockKeyInspect()
MinimockKeyInspect logs each unmet expectation
func (*LockerMock) MinimockLockDone ¶
func (m *LockerMock) MinimockLockDone() bool
MinimockLockDone returns true if the count of the Lock invocations corresponds the number of defined expectations
func (*LockerMock) MinimockLockInspect ¶
func (m *LockerMock) MinimockLockInspect()
MinimockLockInspect logs each unmet expectation
func (*LockerMock) MinimockTryLockDone ¶
func (m *LockerMock) MinimockTryLockDone() bool
MinimockTryLockDone returns true if the count of the TryLock invocations corresponds the number of defined expectations
func (*LockerMock) MinimockTryLockInspect ¶
func (m *LockerMock) MinimockTryLockInspect()
MinimockTryLockInspect logs each unmet expectation
func (*LockerMock) MinimockUnlockDone ¶
func (m *LockerMock) MinimockUnlockDone() bool
MinimockUnlockDone returns true if the count of the Unlock invocations corresponds the number of defined expectations
func (*LockerMock) MinimockUnlockInspect ¶
func (m *LockerMock) MinimockUnlockInspect()
MinimockUnlockInspect logs each unmet expectation
func (*LockerMock) MinimockWait ¶
func (m *LockerMock) MinimockWait(timeout mm_time.Duration)
MinimockWait waits for all mocked methods to be called the expected number of times
func (*LockerMock) TryLock ¶
func (mmTryLock *LockerMock) TryLock(ctx context.Context) (err error)
TryLock implements mm_locker.Locker
func (*LockerMock) TryLockAfterCounter ¶
func (mmTryLock *LockerMock) TryLockAfterCounter() uint64
TryLockAfterCounter returns a count of finished LockerMock.TryLock invocations
func (*LockerMock) TryLockBeforeCounter ¶
func (mmTryLock *LockerMock) TryLockBeforeCounter() uint64
TryLockBeforeCounter returns a count of LockerMock.TryLock invocations
func (*LockerMock) Unlock ¶
func (mmUnlock *LockerMock) Unlock(ctx context.Context) (err error)
Unlock implements mm_locker.Locker
func (*LockerMock) UnlockAfterCounter ¶
func (mmUnlock *LockerMock) UnlockAfterCounter() uint64
UnlockAfterCounter returns a count of finished LockerMock.Unlock invocations
func (*LockerMock) UnlockBeforeCounter ¶
func (mmUnlock *LockerMock) UnlockBeforeCounter() uint64
UnlockBeforeCounter returns a count of LockerMock.Unlock invocations
type LockerMockDoneExpectation ¶
type LockerMockDoneExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
LockerMockDoneExpectation specifies expectation struct of the Locker.Done
type LockerMockDoneResults ¶
type LockerMockDoneResults struct {
// contains filtered or unexported fields
}
LockerMockDoneResults contains results of the Locker.Done
type LockerMockKeyExpectation ¶
type LockerMockKeyExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
LockerMockKeyExpectation specifies expectation struct of the Locker.Key
type LockerMockKeyResults ¶
type LockerMockKeyResults struct {
// contains filtered or unexported fields
}
LockerMockKeyResults contains results of the Locker.Key
type LockerMockLockExpectation ¶
type LockerMockLockExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
LockerMockLockExpectation specifies expectation struct of the Locker.Lock
func (*LockerMockLockExpectation) Then ¶
func (e *LockerMockLockExpectation) Then(err error) *LockerMock
Then sets up Locker.Lock return parameters for the expectation previously defined by the When method
type LockerMockLockExpectationOrigins ¶
type LockerMockLockExpectationOrigins struct {
// contains filtered or unexported fields
}
LockerMockLockOrigins contains origins of expectations of the Locker.Lock
type LockerMockLockParamPtrs ¶
type LockerMockLockParamPtrs struct {
// contains filtered or unexported fields
}
LockerMockLockParamPtrs contains pointers to parameters of the Locker.Lock
type LockerMockLockParams ¶
type LockerMockLockParams struct {
// contains filtered or unexported fields
}
LockerMockLockParams contains parameters of the Locker.Lock
type LockerMockLockResults ¶
type LockerMockLockResults struct {
// contains filtered or unexported fields
}
LockerMockLockResults contains results of the Locker.Lock
type LockerMockTryLockExpectation ¶
type LockerMockTryLockExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
LockerMockTryLockExpectation specifies expectation struct of the Locker.TryLock
func (*LockerMockTryLockExpectation) Then ¶
func (e *LockerMockTryLockExpectation) Then(err error) *LockerMock
Then sets up Locker.TryLock return parameters for the expectation previously defined by the When method
type LockerMockTryLockExpectationOrigins ¶
type LockerMockTryLockExpectationOrigins struct {
// contains filtered or unexported fields
}
LockerMockTryLockOrigins contains origins of expectations of the Locker.TryLock
type LockerMockTryLockParamPtrs ¶
type LockerMockTryLockParamPtrs struct {
// contains filtered or unexported fields
}
LockerMockTryLockParamPtrs contains pointers to parameters of the Locker.TryLock
type LockerMockTryLockParams ¶
type LockerMockTryLockParams struct {
// contains filtered or unexported fields
}
LockerMockTryLockParams contains parameters of the Locker.TryLock
type LockerMockTryLockResults ¶
type LockerMockTryLockResults struct {
// contains filtered or unexported fields
}
LockerMockTryLockResults contains results of the Locker.TryLock
type LockerMockUnlockExpectation ¶
type LockerMockUnlockExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
LockerMockUnlockExpectation specifies expectation struct of the Locker.Unlock
func (*LockerMockUnlockExpectation) Then ¶
func (e *LockerMockUnlockExpectation) Then(err error) *LockerMock
Then sets up Locker.Unlock return parameters for the expectation previously defined by the When method
type LockerMockUnlockExpectationOrigins ¶
type LockerMockUnlockExpectationOrigins struct {
// contains filtered or unexported fields
}
LockerMockUnlockOrigins contains origins of expectations of the Locker.Unlock
type LockerMockUnlockParamPtrs ¶
type LockerMockUnlockParamPtrs struct {
// contains filtered or unexported fields
}
LockerMockUnlockParamPtrs contains pointers to parameters of the Locker.Unlock
type LockerMockUnlockParams ¶
type LockerMockUnlockParams struct {
// contains filtered or unexported fields
}
LockerMockUnlockParams contains parameters of the Locker.Unlock
type LockerMockUnlockResults ¶
type LockerMockUnlockResults struct {
// contains filtered or unexported fields
}
LockerMockUnlockResults contains results of the Locker.Unlock
type TCSClientMock ¶
type TCSClientMock struct {
DoMock mTCSClientMockDo
NewWatcherMock mTCSClientMockNewWatcher
// contains filtered or unexported fields
}
TCSClientMock implements mm_tcs.Client
func NewTCSClientMock ¶
func NewTCSClientMock(t minimock.Tester) *TCSClientMock
NewTCSClientMock returns a mock for mm_tcs.Client
func (*TCSClientMock) Do ¶
func (mmDo *TCSClientMock) Do(req tarantool.Request) (fut tarantool.Future)
Do implements mm_tcs.Client
func (*TCSClientMock) DoAfterCounter ¶
func (mmDo *TCSClientMock) DoAfterCounter() uint64
DoAfterCounter returns a count of finished TCSClientMock.Do invocations
func (*TCSClientMock) DoBeforeCounter ¶
func (mmDo *TCSClientMock) DoBeforeCounter() uint64
DoBeforeCounter returns a count of TCSClientMock.Do invocations
func (*TCSClientMock) MinimockDoDone ¶
func (m *TCSClientMock) MinimockDoDone() bool
MinimockDoDone returns true if the count of the Do invocations corresponds the number of defined expectations
func (*TCSClientMock) MinimockDoInspect ¶
func (m *TCSClientMock) MinimockDoInspect()
MinimockDoInspect logs each unmet expectation
func (*TCSClientMock) MinimockFinish ¶
func (m *TCSClientMock) MinimockFinish()
MinimockFinish checks that all mocked methods have been called the expected number of times
func (*TCSClientMock) MinimockNewWatcherDone ¶
func (m *TCSClientMock) MinimockNewWatcherDone() bool
MinimockNewWatcherDone returns true if the count of the NewWatcher invocations corresponds the number of defined expectations
func (*TCSClientMock) MinimockNewWatcherInspect ¶
func (m *TCSClientMock) MinimockNewWatcherInspect()
MinimockNewWatcherInspect logs each unmet expectation
func (*TCSClientMock) MinimockWait ¶
func (m *TCSClientMock) MinimockWait(timeout mm_time.Duration)
MinimockWait waits for all mocked methods to be called the expected number of times
func (*TCSClientMock) NewWatcher ¶
func (mmNewWatcher *TCSClientMock) NewWatcher(key string, callback tarantool.WatchCallback) (w1 tarantool.Watcher, err error)
NewWatcher implements mm_tcs.Client
func (*TCSClientMock) NewWatcherAfterCounter ¶
func (mmNewWatcher *TCSClientMock) NewWatcherAfterCounter() uint64
NewWatcherAfterCounter returns a count of finished TCSClientMock.NewWatcher invocations
func (*TCSClientMock) NewWatcherBeforeCounter ¶
func (mmNewWatcher *TCSClientMock) NewWatcherBeforeCounter() uint64
NewWatcherBeforeCounter returns a count of TCSClientMock.NewWatcher invocations
type TCSClientMockDoExpectation ¶
type TCSClientMockDoExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
TCSClientMockDoExpectation specifies expectation struct of the Client.Do
func (*TCSClientMockDoExpectation) Then ¶
func (e *TCSClientMockDoExpectation) Then(fut tarantool.Future) *TCSClientMock
Then sets up Client.Do return parameters for the expectation previously defined by the When method
type TCSClientMockDoExpectationOrigins ¶
type TCSClientMockDoExpectationOrigins struct {
// contains filtered or unexported fields
}
TCSClientMockDoOrigins contains origins of expectations of the Client.Do
type TCSClientMockDoParamPtrs ¶
type TCSClientMockDoParamPtrs struct {
// contains filtered or unexported fields
}
TCSClientMockDoParamPtrs contains pointers to parameters of the Client.Do
type TCSClientMockDoParams ¶
type TCSClientMockDoParams struct {
// contains filtered or unexported fields
}
TCSClientMockDoParams contains parameters of the Client.Do
type TCSClientMockDoResults ¶
type TCSClientMockDoResults struct {
// contains filtered or unexported fields
}
TCSClientMockDoResults contains results of the Client.Do
type TCSClientMockNewWatcherExpectation ¶
type TCSClientMockNewWatcherExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
TCSClientMockNewWatcherExpectation specifies expectation struct of the Client.NewWatcher
func (*TCSClientMockNewWatcherExpectation) Then ¶
func (e *TCSClientMockNewWatcherExpectation) Then(w1 tarantool.Watcher, err error) *TCSClientMock
Then sets up Client.NewWatcher return parameters for the expectation previously defined by the When method
type TCSClientMockNewWatcherExpectationOrigins ¶
type TCSClientMockNewWatcherExpectationOrigins struct {
// contains filtered or unexported fields
}
TCSClientMockNewWatcherOrigins contains origins of expectations of the Client.NewWatcher
type TCSClientMockNewWatcherParamPtrs ¶
type TCSClientMockNewWatcherParamPtrs struct {
// contains filtered or unexported fields
}
TCSClientMockNewWatcherParamPtrs contains pointers to parameters of the Client.NewWatcher
type TCSClientMockNewWatcherParams ¶
type TCSClientMockNewWatcherParams struct {
// contains filtered or unexported fields
}
TCSClientMockNewWatcherParams contains parameters of the Client.NewWatcher
type TCSClientMockNewWatcherResults ¶
type TCSClientMockNewWatcherResults struct {
// contains filtered or unexported fields
}
TCSClientMockNewWatcherResults contains results of the Client.NewWatcher
type WatcherMock ¶
type WatcherMock struct {
UnregisterMock mWatcherMockUnregister
// contains filtered or unexported fields
}
WatcherMock implements mm_tarantool.Watcher
func NewWatcherMock ¶
func NewWatcherMock(t minimock.Tester) *WatcherMock
NewWatcherMock returns a mock for mm_tarantool.Watcher
func (*WatcherMock) MinimockFinish ¶
func (m *WatcherMock) MinimockFinish()
MinimockFinish checks that all mocked methods have been called the expected number of times
func (*WatcherMock) MinimockUnregisterDone ¶
func (m *WatcherMock) MinimockUnregisterDone() bool
MinimockUnregisterDone returns true if the count of the Unregister invocations corresponds the number of defined expectations
func (*WatcherMock) MinimockUnregisterInspect ¶
func (m *WatcherMock) MinimockUnregisterInspect()
MinimockUnregisterInspect logs each unmet expectation
func (*WatcherMock) MinimockWait ¶
func (m *WatcherMock) MinimockWait(timeout mm_time.Duration)
MinimockWait waits for all mocked methods to be called the expected number of times
func (*WatcherMock) Unregister ¶
func (mmUnregister *WatcherMock) Unregister()
Unregister implements mm_tarantool.Watcher
func (*WatcherMock) UnregisterAfterCounter ¶
func (mmUnregister *WatcherMock) UnregisterAfterCounter() uint64
UnregisterAfterCounter returns a count of finished WatcherMock.Unregister invocations
func (*WatcherMock) UnregisterBeforeCounter ¶
func (mmUnregister *WatcherMock) UnregisterBeforeCounter() uint64
UnregisterBeforeCounter returns a count of WatcherMock.Unregister invocations
type WatcherMockUnregisterExpectation ¶
type WatcherMockUnregisterExpectation struct {
Counter uint64
// contains filtered or unexported fields
}
WatcherMockUnregisterExpectation specifies expectation struct of the Watcher.Unregister