def METHOD_NAME(self):
    app = flask.Flask(__name__)
    class Index(flask.views.MethodView):
        def get(self):
            return 'GET'
        def head(self):
            return flask.Response('', headers={'X-Method': 'HEAD'})
    app.add_url_rule('/', view_func=Index.as_view('index'))
    c = app.test_client()
    rv = c.get('/')
    self.assert_equal(rv.data, b'GET')
    rv = c.head('/')
    self.assert_equal(rv.data, b'')
    self.assert_equal(rv.headers['X-Method'], 'HEAD')