'The X_FRAME_OPTIONS setting can be set to SAMEORIGIN to have the
middleware use that value for the HTTP header.'

def test_same_origin(self):

    with override_settings(X_FRAME_OPTIONS='SAMEORIGIN'):
        r = XFrameOptionsMiddleware().process_response(HttpRequest(), HttpResponse())
        self.assertEqual(r['X-Frame-Options'], 'SAMEORIGIN')
    with override_settings(X_FRAME_OPTIONS='sameorigin'):
        r = XFrameOptionsMiddleware().process_response(HttpRequest(), HttpResponse())
        self.assertEqual(r['X-Frame-Options'], 'SAMEORIGIN')
