mirror of
https://github.com/apache/superset.git
synced 2026-04-18 07:35:09 +00:00
chore: move SLACK_ENABLE_AVATARS from config to feature flag (#30274)
This commit is contained in:
committed by
GitHub
parent
46b1d869b1
commit
f315a4f02c
@@ -22,7 +22,7 @@ from unittest.mock import patch
|
||||
from superset import security_manager
|
||||
from superset.utils import json, slack # noqa: F401
|
||||
from tests.integration_tests.base_tests import SupersetTestCase
|
||||
from tests.integration_tests.conftest import with_config
|
||||
from tests.integration_tests.conftest import with_config, with_feature_flags
|
||||
from tests.integration_tests.constants import ADMIN_USERNAME
|
||||
|
||||
meUri = "/api/v1/me/"
|
||||
@@ -81,7 +81,8 @@ class TestUserApi(SupersetTestCase):
|
||||
response = self.client.get("/api/v1/user/1/avatar.png", follow_redirects=False)
|
||||
assert response.status_code == 204
|
||||
|
||||
@with_config({"SLACK_API_TOKEN": "dummy", "SLACK_ENABLE_AVATARS": True})
|
||||
@with_config({"SLACK_API_TOKEN": "dummy"})
|
||||
@with_feature_flags(SLACK_ENABLE_AVATARS=True)
|
||||
@patch("superset.views.users.api.get_user_avatar", return_value=AVATAR_URL)
|
||||
def test_avatar_with_valid_user(self, mock):
|
||||
self.login(ADMIN_USERNAME)
|
||||
|
||||
Reference in New Issue
Block a user