<p><b>@gravitystorm</b> commented on this pull request.</p>

<hr>

<p>In <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2496#discussion_r364352911">test/controllers/users_controller_test.rb</a>:</p>
<pre style='color:#555'>> @@ -344,27 +344,13 @@ def test_save_referer_params
   end
 
   def test_logout_without_referer
-    get :logout
-    assert_response :success
-    assert_template :logout
-    assert_select "input[name=referer][value=?]", ""
-
-    session_id = assert_select("input[name=session]").first["value"]
-
-    get :logout, :params => { :session => session_id }
</pre>
<p>Sure, I've added those bits of the tests back in. I've also added a system test that clicks the button and checks the redirect, as well as a system test that checks the referer works for normal behaviour.</p>
<p>(I added the last two as system tests, since I dislike writing controller tests where you check the form, and then try submitting a facsimile of what you hope the browser sends)</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2496?email_source=notifications&email_token=AAK2OLMD7BGOH6OY62B7W7TQ4YEVHA5CNFSM4KEIBWS2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOCRCGBHQ#discussion_r364352911">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLL5NB4HCYEOVT6CAJDQ4YEVHANCNFSM4KEIBWSQ">unsubscribe</a>.<img src="https://github.com/notifications/beacon/AAK2OLK2JTZPH3PKHE4L62TQ4YEVHA5CNFSM4KEIBWS2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOCRCGBHQ.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/pull/2496?email_source=notifications\u0026email_token=AAK2OLMD7BGOH6OY62B7W7TQ4YEVHA5CNFSM4KEIBWS2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOCRCGBHQ#discussion_r364352911",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/2496?email_source=notifications\u0026email_token=AAK2OLMD7BGOH6OY62B7W7TQ4YEVHA5CNFSM4KEIBWS2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOCRCGBHQ#discussion_r364352911",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>