mirror of
https://github.com/cloudreve/Cloudreve.git
synced 2026-11-17 22:58:07 +00:00
Fix: untracked files
This commit is contained in:
1 parent
132c7a8fcb
commit
2b8921e9fd
17 files changed
+623
-42
No files matched your search
@@ -160,3 +160,9 @@ func (handler Handler) Source(
|
||||
finalURL := baseURL.ResolveReference(signedURI).String()
|
||||
return finalURL, nil
|
||||
}
|
||||
|
||||
// Token 获取上传策略和认证Token,本地策略直接返回空值
|
||||
// TODO 测试
|
||||
func (handler Handler) Token(ctx context.Context, ttl int64, key string) (serializer.UploadCredential, error) {
|
||||
return serializer.UploadCredential{}, nil
|
||||
}
|
||||
@@ -184,3 +184,11 @@ func TestHandler_GetDownloadURL(t *testing.T) {
|
||||
asserts.Empty(downloadURL)
|
||||
}
|
||||
}
|
||||
|
||||
func TestHandler_Token(t *testing.T) {
|
||||
asserts := assert.New(t)
|
||||
handler := Handler{}
|
||||
ctx := context.Background()
|
||||
_, err := handler.Token(ctx, 10, "123")
|
||||
asserts.NoError(err)
|
||||
}
|
||||
Reference in new issue
Block a user