Skip to content

Commit

Permalink
fix tests part 6
Browse files Browse the repository at this point in the history
  • Loading branch information
dpgaspar committed May 31, 2024
1 parent b81d10f commit 870282d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions tests/test_custom_indexview.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ class CustomIndexView(IndexView):
class FlaskTestCase(FABTestCase):
def setUp(self):
from flask import Flask

self.app = Flask(__name__, template_folder=".")
self.basedir = os.path.abspath(os.path.dirname(__file__))
self.app.config.from_object("tests.config_api")
Expand Down
6 changes: 5 additions & 1 deletion tests/test_urltools.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,13 @@ def setUp(self):
self.app = Flask(__name__)
self.basedir = os.path.abspath(os.path.dirname(__file__))
self.app.config.from_object("tests.config_api")

self.ctx = self.app.app_context()
self.ctx.push()
self.appbuilder = AppBuilder(self.app)

def tearDown(self):
self.ctx.pop()

def test_get_filter_args_allow_one(self):
datamodel = SQLAInterface(Model1)
with self.appbuilder.get_app.test_request_context(
Expand Down

0 comments on commit 870282d

Please sign in to comment.