File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change 22GitLab API: https://docs.gitlab.com/ee/api/statistics.html
33"""
44
5+ from itertools import count
56from tests .functional .conftest import reset_gitlab
67
78
@@ -31,6 +32,6 @@ def test_get_statistics(gl):
3132
3233 statistics = gl .statistics .get ()
3334 assert statistics .snippets == "1"
34- assert statistics .users == "1"
35+ assert statistics .users == str ( 1 + count ( gl . users . list ( search = "ghost" )))
3536 assert statistics .groups == "2"
3637 assert statistics .projects == "1"
Original file line number Diff line number Diff line change 11import dataclasses
2+ from itertools import count
23import logging
34import pathlib
45import tempfile
@@ -128,6 +129,8 @@ def reset_gitlab(gl: gitlab.Gitlab) -> None:
128129 if user .username not in ["root" , "ghost" ]:
129130 logging .info (f"Deleting user: { user .username !r} " )
130131 helpers .safe_delete (user , hard_delete = True )
132+ users_left = gl .users .list (search = "ghost" )
133+ print (f"users left: { count (users_left )} " )
131134
132135
133136def set_token (container : str , fixture_dir : pathlib .Path ) -> str :
You can’t perform that action at this time.
0 commit comments