summaryrefslogtreecommitdiff
path: root/tests/unit/conftest.py
diff options
context:
space:
mode:
authorNejc Habjan <hab.nejc@gmail.com>2021-12-01 01:04:53 +0100
committerGitHub <noreply@github.com>2021-12-01 01:04:53 +0100
commit8d76826fa64460e504acc5924f859f8dbc246b42 (patch)
tree083fefada982c795e2415092794db429abb0c184 /tests/unit/conftest.py
parent5a1678f43184bd459132102cc13cf8426fe0449d (diff)
parent86ab04e54ea4175f10053decfad5086cda7aa024 (diff)
downloadgitlab-master.tar.gz
Merge pull request #1723 from python-gitlab/jlvillal/dead_mastermaster
Close-out `master` branch
Diffstat (limited to 'tests/unit/conftest.py')
-rw-r--r--tests/unit/conftest.py84
1 files changed, 0 insertions, 84 deletions
diff --git a/tests/unit/conftest.py b/tests/unit/conftest.py
deleted file mode 100644
index f58c77a..0000000
--- a/tests/unit/conftest.py
+++ /dev/null
@@ -1,84 +0,0 @@
-import pytest
-
-import gitlab
-
-
-@pytest.fixture
-def gl():
- return gitlab.Gitlab(
- "http://localhost",
- private_token="private_token",
- ssl_verify=True,
- api_version="4",
- )
-
-
-@pytest.fixture
-def gl_retry():
- return gitlab.Gitlab(
- "http://localhost",
- private_token="private_token",
- ssl_verify=True,
- api_version="4",
- retry_transient_errors=True,
- )
-
-
-# Todo: parametrize, but check what tests it's really useful for
-@pytest.fixture
-def gl_trailing():
- return gitlab.Gitlab(
- "http://localhost/", private_token="private_token", api_version="4"
- )
-
-
-@pytest.fixture
-def default_config(tmpdir):
- valid_config = """[global]
- default = one
- ssl_verify = true
- timeout = 2
-
- [one]
- url = http://one.url
- private_token = ABCDEF
- """
-
- config_path = tmpdir.join("python-gitlab.cfg")
- config_path.write(valid_config)
- return str(config_path)
-
-
-@pytest.fixture
-def tag_name():
- return "v1.0.0"
-
-
-@pytest.fixture
-def group(gl):
- return gl.groups.get(1, lazy=True)
-
-
-@pytest.fixture
-def project(gl):
- return gl.projects.get(1, lazy=True)
-
-
-@pytest.fixture
-def project_issue(project):
- return project.issues.get(1, lazy=True)
-
-
-@pytest.fixture
-def project_merge_request(project):
- return project.mergerequests.get(1, lazy=True)
-
-
-@pytest.fixture
-def release(project, tag_name):
- return project.releases.get(tag_name, lazy=True)
-
-
-@pytest.fixture
-def user(gl):
- return gl.users.get(1, lazy=True)