Skip to content

Commit

Permalink
Re-ordered blueprint registration.
Browse files Browse the repository at this point in the history
Signed-off-by: Md Safiyat Reza <[email protected]>
  • Loading branch information
safiyat committed Jul 16, 2024
1 parent df57679 commit ab3612a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/test_get_current_registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ class MockResource(Resource):
def get(self):
return "OK", 200, {"Access-Control-Allow-Origin": "*"}

app.register_blueprint(my_blueprint1, url_prefix="")
api1.add_resource(MockResource, "/some/urls")
app.register_blueprint(my_blueprint1, url_prefix="")

with app.test_request_context(path="some_path.html"):
registry = _get_current_registry(api=api1)
Expand Down Expand Up @@ -101,7 +101,6 @@ def test_get_current_registry_request_features_and_docs():
app = Flask(__name__)
app.config["basePath"] = "/abc/123"
my_blueprint1 = Blueprint("my_blueprint1", __name__)
app.register_blueprint(my_blueprint1, url_prefix="")
_ = swagger.docs(
Api(my_blueprint1),
apiVersion="0.1",
Expand All @@ -111,6 +110,7 @@ def test_get_current_registry_request_features_and_docs():
api_spec_url="/api/spec",
description="Blueprint1 Description",
)
app.register_blueprint(my_blueprint1, url_prefix="")

with app.test_request_context(path="some_path.html"):
registry = _get_current_registry()
Expand Down

0 comments on commit ab3612a

Please sign in to comment.