summaryrefslogtreecommitdiff
path: root/tests/testutils/repo/git.py
diff options
context:
space:
mode:
authorBenjamin Schubert <contact@benschubert.me>2020-05-09 12:24:37 +0100
committerBenjamin Schubert <contact@benschubert.me>2020-05-09 12:24:37 +0100
commit576e3da33e8b977a33e997d4ce80dc3c17d5da15 (patch)
treec71f69d572eebb2bdb0d5688a2281395845cbb67 /tests/testutils/repo/git.py
parent1fe5189e5fffbd6ca7465a08f3e41c94cd5d5d23 (diff)
downloadbuildstream-bschubert/cache-key-as-source-test.tar.gz
fixup! cachekey.py: Move source tests for cache keys in sourcetestsbschubert/cache-key-as-source-test
Diffstat (limited to 'tests/testutils/repo/git.py')
-rw-r--r--tests/testutils/repo/git.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/testutils/repo/git.py b/tests/testutils/repo/git.py
index 1deca3ff7..f8af28e33 100644
--- a/tests/testutils/repo/git.py
+++ b/tests/testutils/repo/git.py
@@ -107,3 +107,20 @@ class Git(Repo):
def rev_parse(self, rev):
return self._run_git("rev-parse", rev, stdout=subprocess.PIPE, universal_newlines=True,).stdout.strip()
+
+ def get_element_and_keys_for_cache_key_stability_test(self):
+ return [
+ (
+ {
+ "kind": "import",
+ "sources": [
+ {
+ "kind": "git",
+ "url": "https://example.com/git/repo.git",
+ "ref": "6ac68af3e80b7b17c23a3c65233043550a7fa685"
+ }
+ ]
+ },
+ "4e21bc1089066998d44933fdf1e48b2a5a73ceaba7a3944538f3f142e34b8b8e"
+ )
+ ]