def test_run_hassle(client):
  """Tests /hassle route."""
  with client.session_transaction() as session:
    utils.login(session)
    utils.add_permission(session, Permissions.HASSLE)
  response = client.get(flask.url_for('hassle.run_hassle'))
  assert response.status_code == http.client.OK
Exemplo n.º 2
0
def test_run_hassle(client):
    """Tests /hassle route."""
    with client.session_transaction() as session:
        utils.login(session)
        utils.add_permission(session, Permissions.HASSLE)
    response = client.get(flask.url_for('hassle.run_hassle'))
    assert response.status_code == http.client.OK
Exemplo n.º 3
0
def test_admin_home(client):
  """Tests the /admin route."""
  with client.session_transaction() as session:
    utils.login(session)
    utils.add_permission(session, Permissions.ADMIN)
  response = client.get(flask.url_for('admin.admin_home'))
  assert response.status_code == http.client.OK