Remove robots.txt

Google’s documentation says:

> robots.txt is not a mechanism for keeping a web page out of Google. To
> keep a web page out of Google, you should use noindex directives

We’ve implemented a noindex directive now, so we don’t need to serve
robots.txt any more.
This commit is contained in:
Chris Hill-Scott
2020-05-26 17:47:43 +01:00
parent f902205ef3
commit f12f0fae87
3 changed files with 2 additions and 27 deletions

View File

@@ -63,18 +63,8 @@ def test_logged_in_user_redirects_to_choose_account(
)
def test_robots(client):
assert url_for('main.robots') == '/robots.txt'
response = client.get(url_for('main.robots'))
assert response.headers['Content-Type'] == 'text/plain'
assert response.status_code == 200
assert response.get_data(as_text=True) == (
'User-agent: *\n'
'Disallow: /sign-in\n'
'Disallow: /support\n'
'Disallow: /support/\n'
'Disallow: /register\n'
)
def test_robots(client_request):
client_request.get_url('/robots.txt', _expected_status=404)
@pytest.mark.parametrize('endpoint, kwargs', (