Skip to content

Commit

Permalink
maybe
Browse files Browse the repository at this point in the history
  • Loading branch information
hughhhh committed Apr 4, 2023
1 parent 4017244 commit 060d644
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
9 changes: 2 additions & 7 deletions tests/integration_tests/tags/dao_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ def create_tags(self):
)
)
yield tags
db.session.commit()

@pytest.fixture()
def create_tagged_objects(self):
Expand Down Expand Up @@ -124,12 +123,6 @@ def create_tagged_objects(self):

yield tagged_objects

for tag in tags:
db.session.add(tag)
for tagged_obj in tagged_objects:
db.session.add(tagged_obj)
db.session.commit()

@pytest.mark.usefixtures("load_world_bank_dashboard_with_slices")
@pytest.mark.usefixtures("with_tagging_system_feature")
# test create tag
Expand Down Expand Up @@ -303,3 +296,5 @@ def test_delete_tagged_object(self):
def test_validate_tag_name(self):
assert TagDAO.validate_tag_name("example_tag_name") is True
assert TagDAO.validate_tag_name("invalid:tag_name") is False
db.session.query(Tag).delete()
db.session.query(TaggedObject).delete()
2 changes: 2 additions & 0 deletions tests/integration_tests/tasks/async_queries_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,13 @@
load_birth_names_data,
)
from tests.integration_tests.fixtures.query_context import get_query_context
from tests.integration_tests.fixtures.tags import with_tagging_system_feature
from tests.integration_tests.test_app import app


class TestAsyncQueries(SupersetTestCase):
@pytest.mark.usefixtures("load_birth_names_dashboard_with_slices")
@pytest.mark.usefixtures("with_tagging_system_feature")
@mock.patch.object(async_query_manager, "update_job")
@mock.patch.object(async_queries, "set_form_data")
def test_load_chart_data_into_cache(self, mock_set_form_data, mock_update_job):
Expand Down

0 comments on commit 060d644

Please sign in to comment.