Procházet zdrojové kódy

support/testing: add gitlab download helper testing

Like for the github helper, add some tests to test the download of
Gitlab's generated tarball.

[1] f83826c90daf9cdb5a6196d2d2830eea8c2f0e09

Signed-off-by: Romain Naour <romain.naour@gmail.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Cc: Yann E. MORIN <yann.morin.1998@free.fr>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Romain Naour před 3 roky
rodič
revize
8cce2ce1d2

+ 0 - 0
support/testing/tests/download/br2-external/gitlab/Config.in


+ 1 - 0
support/testing/tests/download/br2-external/gitlab/external.desc

@@ -0,0 +1 @@
+name: GITLAB

+ 1 - 0
support/testing/tests/download/br2-external/gitlab/external.mk

@@ -0,0 +1 @@
+include $(sort $(wildcard $(BR2_EXTERNAL_GITLAB_PATH)/package/*/*.mk))

+ 3 - 0
support/testing/tests/download/br2-external/gitlab/package/gitlab-helper-hash/gitlab-helper-hash.hash

@@ -0,0 +1,3 @@
+# Locally computed
+sha256  28f3b63454a7de6d8fb154dfa1e2e203afeb34db006661329e273137f8fe3dce  gitlab-helper-hash-21a378a7858460809ffef1c96a07a493d709730c.tar.gz
+sha256  309875d925041d909bc705473d6c4b7905272aea15c1c2389088c26c161bae1f  license.txt

+ 12 - 0
support/testing/tests/download/br2-external/gitlab/package/gitlab-helper-hash/gitlab-helper-hash.mk

@@ -0,0 +1,12 @@
+################################################################################
+#
+# gitlab-helper-hash
+#
+################################################################################
+
+GITLAB_HELPER_HASH_VERSION = 21a378a7858460809ffef1c96a07a493d709730c
+GITLAB_HELPER_HASH_SITE = $(call gitlab,solarus-games,solarus,$(GITLAB_HELPER_HASH_VERSION))
+
+GITLAB_HELPER_HASH_LICENSE_FILES = license.txt
+
+$(eval $(generic-package))

+ 3 - 0
support/testing/tests/download/br2-external/gitlab/package/gitlab-helper-tag/gitlab-helper-tag.hash

@@ -0,0 +1,3 @@
+# Locally computed
+sha256  ef08b22999431b7f81f9b74408221b8a5a3ab5b0f646a835443a3c37cb2fb979  gitlab-helper-tag-1.6.5.tar.gz
+sha256  309875d925041d909bc705473d6c4b7905272aea15c1c2389088c26c161bae1f  license.txt

+ 11 - 0
support/testing/tests/download/br2-external/gitlab/package/gitlab-helper-tag/gitlab-helper-tag.mk

@@ -0,0 +1,11 @@
+################################################################################
+#
+# gitlab-helper-tag
+#
+################################################################################
+
+GITLAB_HELPER_TAG_VERSION = 1.6.5
+GITLAB_HELPER_TAG_SITE = $(call gitlab,solarus-games,solarus,v$(GITLAB_HELPER_TAG_VERSION))
+GITLAB_HELPER_TAG_LICENSE_FILES = license.txt
+
+$(eval $(generic-package))

+ 3 - 0
support/testing/tests/download/br2-external/gitlab/package/gitlab-release/gitlab-release.hash

@@ -0,0 +1,3 @@
+# Locally calculated
+sha256 12b88efa4d0d95af08db05a50b3dcb217c0eb2bfc67b483779e33d498ddb2f95  iucode-tool_2.3.1.tar.xz
+sha256 ab15fd526bd8dd18a9e77ebc139656bf4d33e97fc7238cd11bf60e2b9b8666c6  COPYING

+ 12 - 0
support/testing/tests/download/br2-external/gitlab/package/gitlab-release/gitlab-release.mk

@@ -0,0 +1,12 @@
+################################################################################
+#
+# gitlab-release
+#
+################################################################################
+
+GITLAB_RELEASE_VERSION = 2.3.1
+GITLAB_RELEASE_SITE = https://gitlab.com/iucode-tool/releases/raw/master
+GITLAB_RELEASE_SOURCE = iucode-tool_$(GITLAB_RELEASE_VERSION).tar.xz
+GITLAB_RELEASE_LICENSE_FILES = COPYING
+
+$(eval $(generic-package))

+ 8 - 0
support/testing/tests/download/test_gitforge.py

@@ -39,3 +39,11 @@ class TestGitHub(GitforgeTestBase):
         self.check_download("github-helper-hash")
         self.check_download("github-helper-hash")
         self.check_download("github-release")
         self.check_download("github-release")
 
 
+
+class TestGitLab(GitforgeTestBase):
+    br2_external = [infra.filepath("tests/download/br2-external/gitlab")]
+
+    def test_run(self):
+        self.check_download("gitlab-helper-hash")
+        self.check_download("gitlab-helper-tag")
+        self.check_download("gitlab-release")