getTestBucket returns a bucket from the bucket pool. Persistent flag determines behaviour for walrus buckets only - Couchbase bucket behaviour is defined by the bucket pool readier/init.
(t testing.TB, persistent bool)
| 108 | // getTestBucket returns a bucket from the bucket pool. Persistent flag determines behaviour for walrus |
| 109 | // buckets only - Couchbase bucket behaviour is defined by the bucket pool readier/init. |
| 110 | func getTestBucket(t testing.TB, persistent bool) *TestBucket { |
| 111 | bucket, spec, closeFn := GTestBucketPool.getTestBucketAndSpec(t, persistent) |
| 112 | return &TestBucket{ |
| 113 | Bucket: bucket, |
| 114 | BucketSpec: spec, |
| 115 | closeFn: closeFn, |
| 116 | t: t, |
| 117 | } |
| 118 | } |
| 119 | |
| 120 | // GetNamedDataStore returns a named datastore from the TestBucket. Each number (starting from 0, indicates which data store you'll get. |
| 121 | func (tb *TestBucket) GetNamedDataStore(count int) (DataStore, error) { |