|
|
@ -2,6 +2,7 @@ package foundationdb |
|
|
|
|
|
|
|
|
import ( |
|
|
import ( |
|
|
"context" |
|
|
"context" |
|
|
|
|
|
"fmt" |
|
|
"sort" |
|
|
"sort" |
|
|
"strings" |
|
|
"strings" |
|
|
"testing" |
|
|
"testing" |
|
|
@ -157,14 +158,20 @@ func (store *MockFoundationDBStore) ListDirectoryPrefixedEntries(ctx context.Con |
|
|
continue |
|
|
continue |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if !eachEntryFunc(entry) { |
|
|
|
|
|
|
|
|
resEachEntryFunc, resEachEntryFuncErr := eachEntryFunc(entry) |
|
|
|
|
|
if resEachEntryFuncErr != nil { |
|
|
|
|
|
err = fmt.Errorf("failed to process eachEntryFunc: %w", resEachEntryFuncErr) |
|
|
break |
|
|
break |
|
|
} |
|
|
} |
|
|
|
|
|
if !resEachEntryFunc { |
|
|
|
|
|
break |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
lastFileName = entry.Name() |
|
|
lastFileName = entry.Name() |
|
|
count++ |
|
|
count++ |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
return lastFileName, nil |
|
|
|
|
|
|
|
|
return lastFileName, err |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
func (store *MockFoundationDBStore) KvPut(ctx context.Context, key []byte, value []byte) error { |
|
|
func (store *MockFoundationDBStore) KvPut(ctx context.Context, key []byte, value []byte) error { |
|
|
|