chore(dao): Add explicit ON DELETE CASCADE for ownership (#24628)

This commit is contained in:
John Bodley
2023-07-11 11:39:03 -07:00
committed by GitHub
parent b4d08aecdb
commit ae00489779
19 changed files with 200 additions and 120 deletions

View File

@@ -146,9 +146,6 @@ class TestImportAssetsCommand(SupersetTestCase):
assert dashboard.owners == [self.user]
dashboard.owners = []
chart.owners = []
database.owners = []
db.session.delete(dashboard)
db.session.delete(chart)
db.session.delete(dataset)
@@ -190,10 +187,6 @@ class TestImportAssetsCommand(SupersetTestCase):
chart = dashboard.slices[0]
dataset = chart.table
database = dataset.database
dashboard.owners = []
chart.owners = []
database.owners = []
db.session.delete(dashboard)
db.session.delete(chart)
db.session.delete(dataset)