fix(datasource): align Feishu connector capabilities
This commit is contained in:
@@ -92,7 +92,7 @@ var ConnectorMetadataRegistry = map[string]ConnectorMetadata{
|
|||||||
Description: "Sync documents, wikis, and content from Feishu",
|
Description: "Sync documents, wikis, and content from Feishu",
|
||||||
Priority: 0,
|
Priority: 0,
|
||||||
AuthType: "oauth2",
|
AuthType: "oauth2",
|
||||||
Capabilities: []string{"incremental", "webhook", "deletion_sync"},
|
Capabilities: []string{"incremental", "deletion_sync"},
|
||||||
},
|
},
|
||||||
types.ConnectorTypeNotion: {
|
types.ConnectorTypeNotion: {
|
||||||
Type: types.ConnectorTypeNotion,
|
Type: types.ConnectorTypeNotion,
|
||||||
|
|||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package datasource
|
||||||
|
|
||||||
|
import (
|
||||||
|
"testing"
|
||||||
|
|
||||||
|
"github.com/Tencent/WeKnora/internal/types"
|
||||||
|
)
|
||||||
|
|
||||||
|
func TestFeishuMetadataDoesNotAdvertiseWebhook(t *testing.T) {
|
||||||
|
meta := ConnectorMetadataRegistry[types.ConnectorTypeFeishu]
|
||||||
|
|
||||||
|
for _, capability := range meta.Capabilities {
|
||||||
|
if capability == "webhook" {
|
||||||
|
t.Fatalf("Feishu connector should not advertise webhook until webhook sync is implemented")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user