MCPcopy Create free account
hub / github.com/dropbox/dbxcli / TestResolveDestination_TargetIsFolder

Function TestResolveDestination_TargetIsFolder

cmd/put_test.go:371–381  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

369}
370
371func TestResolveDestination_TargetIsFolder(t *testing.T) {
372 mock := &mockFilesClient{
373 getMetadataFn: func(arg *files.GetMetadataArg) (files.IsMetadata, error) {
374 return &files.FolderMetadata{Metadata: files.Metadata{PathDisplay: arg.Path}}, nil
375 },
376 }
377 got := resolveDestination(mock, "/local/video.mp4", "/Videos", false)
378 if got != "/Videos/video.mp4" {
379 t.Errorf("resolveDestination = %q, want /Videos/video.mp4", got)
380 }
381}
382
383func TestResolveDestination_TargetIsFile(t *testing.T) {
384 mock := &mockFilesClient{

Callers

nothing calls this directly

Calls 1

resolveDestinationFunction · 0.85

Tested by

no test coverage detected