'Test that Log middleware is executed'

def test_log_get_request(self):

    global context
    app = falcon.API(middleware=[RequestTimeMiddleware()])
    app.add_route(TEST_ROUTE, MiddlewareClassResource())
    client = testing.TestClient(app)
    response = client.simulate_request(path=TEST_ROUTE)
    assert (_EXPECTED_BODY == response.json)
    assert (response.status == falcon.HTTP_200)
    assert ('start_time' in context)
    assert ('mid_time' in context)
    assert ('end_time' in context)
    assert (context['mid_time'] >= context['start_time']), 'process_resource    not    executed    after    request'
    assert (context['end_time'] >= context['start_time']), 'process_response    not    executed    after    request'
    assert context['req_succeeded']
