def mock_dataset_with_config(mocker, mock_dataset, dataset_config_response):
    """Returns an example dataset, mocked to return a configuration."""

    mocker.patch.object(
        mock_dataset, 'get', return_value=dataset_config_response)
    mock_dataset.attributes
    return mock_dataset