diff --git a/tests/functional/api/test_gitlab.py b/tests/functional/api/test_gitlab.py index 08f9d9a4c..f2bdf5099 100644 --- a/tests/functional/api/test_gitlab.py +++ b/tests/functional/api/test_gitlab.py @@ -126,6 +126,7 @@ def test_hooks(gl): def test_namespaces(gl, get_all_kwargs): + gl.auth() current_user = gl.user.username namespaces = gl.namespaces.list(**get_all_kwargs) @@ -239,7 +240,11 @@ def test_list_all_false_nowarning(gl, recwarn): def test_list_all_true_nowarning(gl, get_all_kwargs, recwarn): """Using `get_all=True` will disable the warning""" items = gl.gitlabciymls.list(**get_all_kwargs) - assert not recwarn + for warn in recwarn: + if issubclass(warn.category, UserWarning): + # Our warning has a link to the docs in it, make sure we don't have + # that. + assert "python-gitlab.readthedocs.io" not in str(warn.message) assert len(items) > 20