def METHOD_NAME(client):
    view_data = {
        'view': {
            'name': 'test_create_view_duplicate',
            'query': 'SELECT * FROM example_db.house_sales'
        }
    }
    response = client.post('/api/projects/mindsdb/views', json=view_data, follow_redirects=True)
    assert '201' in response.status
    create_duplicate_response = client.post('/api/projects/mindsdb/views', json=view_data, follow_redirects=True)
    # Make sure we use CONFLICT status code.
    assert '409' in create_duplicate_response.status