From 1aec0290af72f91db6eedd648fba0bb637e3dea7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Bonhomme?= Date: Mon, 6 Jan 2020 18:10:30 +0100 Subject: [PATCH] checkout version curl-7_67_0 of curl for the tests. --- tests/conftest.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 tests/conftest.py diff --git a/tests/conftest.py b/tests/conftest.py new file mode 100644 index 0000000..5267a2e --- /dev/null +++ b/tests/conftest.py @@ -0,0 +1,19 @@ + +import os +import pytest + +from git import Repo + + +@pytest.fixture(scope='session') +def clone_curl(): + """Clone the repository of curl for the tests.""" + git_url = 'https://github.com/curl/curl.git' + repo_dir = './test_repos/curl' + repo = Repo.clone_from(url=git_url, to_path=repo_dir) + repo.checkout('curl-7_67_0') + + def teardown(): + os.unlink(repo_dir) + + return repo_dir