mirror of
https://github.com/langgenius/dify-plugin-sdks.git
synced 2026-07-22 10:25:23 -04:00
34cf20564b
- Modified the test for `oauth_get_authorization_url` to pass a redirect URI as the first argument, ensuring proper functionality and coverage. This change enhances the accuracy of the test case for the TriggerProvider's OAuth implementation.
21 lines
554 B
Python
21 lines
554 B
Python
import pytest
|
|
|
|
from dify_plugin.interfaces.trigger import TriggerProvider
|
|
|
|
|
|
def test_construct_trigger_provider():
|
|
"""
|
|
Test that the TriggerProvider can be constructed without implementing any methods
|
|
"""
|
|
provider = TriggerProvider()
|
|
assert provider is not None
|
|
|
|
|
|
def test_oauth_get_authorization_url():
|
|
"""
|
|
Test that the TriggerProvider can get the authorization url
|
|
"""
|
|
provider = TriggerProvider()
|
|
with pytest.raises(NotImplementedError):
|
|
provider.oauth_get_authorization_url("http://redirect.uri", {})
|