Skip to content
Snippets Groups Projects
Commit 9ef44a54 authored by Erik Reid's avatar Erik Reid
Browse files

don't require json on testing route

parent 394c5de8
No related branches found
No related tags found
No related merge requests found
......@@ -5,7 +5,6 @@ routes = Blueprint("inventory-data-testing-support-routes", __name__)
@routes.route("/flushdb", methods=['GET', 'POST'])
@common.require_accepts_json
def flushdb():
common.get_redis().flushdb()
return Response('OK')
import json
import jsonschema
DEFAULT_REQUEST_HEADERS = {
"Content-type": "application/json",
"Accept": ["application/json"]
}
def test_flushdb(client):
rv = client.post(
"/testing/flushdb",
headers=DEFAULT_REQUEST_HEADERS)
rv = client.post("/testing/flushdb")
assert rv.status_code == 200
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment