diff --git a/debian/control b/debian/control --- a/debian/control +++ b/debian/control @@ -8,6 +8,7 @@ python3-all, python3-debian, python3-nose, + python3-requests-mock, python3-setuptools, python3-sqlalchemy, python3-swh.core, diff --git a/requirements-test.txt b/requirements-test.txt --- a/requirements-test.txt +++ b/requirements-test.txt @@ -1 +1,3 @@ pytest +requests-mock +sqlalchemy diff --git a/swh/loader/debian/tests/__init__.py b/swh/loader/debian/tests/__init__.py --- a/swh/loader/debian/tests/__init__.py +++ b/swh/loader/debian/tests/__init__.py @@ -0,0 +1,27 @@ +import os + +TEST_LOADER_CONFIG = { + 'storage': { + 'cls': 'memory', + 'args': { + } + }, + 'send_contents': True, + 'send_directories': True, + 'send_revisions': True, + 'send_releases': True, + 'send_snapshot': True, + + 'content_size_limit': 100 * 1024 * 1024, + 'content_packet_size': 10, + 'content_packet_size_bytes': 100 * 1024 * 1024, + 'directory_packet_size': 10, + 'revision_packet_size': 10, + 'release_packet_size': 10, + + 'save_data': False, + + 'lister_db_url': + 'postgresql+psycopg2:///test-lister-debian?host={PGHOST}'.format( + **os.environ) +} diff --git a/swh/loader/debian/tests/resources/hello_2.10-1+deb9u1.debian.tar.xz b/swh/loader/debian/tests/resources/hello_2.10-1+deb9u1.debian.tar.xz new file mode 100644 index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 GIT binary patch literal 0 Hc$@ +Homepage: http://www.gnu.org/software/hello/ +Standards-Version: 3.9.6 +Build-Depends: debhelper (>= 9.20120311) +Package-List: + hello deb devel optional arch=any +Checksums-Sha1: + f7bebf6f9c62a2295e889f66e05ce9bfaed9ace3 725946 hello_2.10.orig.tar.gz + c29e15965f370fb9e3c742113b6ce5704ad2761c 6156 hello_2.10-1+deb9u1.debian.tar.xz +Checksums-Sha256: + 31e066137a962676e89f69d1b65382de95a7ef7d914b8cb956f41ea72e0f516b 725946 hello_2.10.orig.tar.gz + 8f8031f001112e1c869907e77fdc730733cf591c4d66b74252eb0d669d1dfb01 6156 hello_2.10-1+deb9u1.debian.tar.xz +Files: + 6cd0ffea3884a4e79330338dcc2987d6 725946 hello_2.10.orig.tar.gz + 8b0ca540355860aaea1cfc96f2aaa18f 6156 hello_2.10-1+deb9u1.debian.tar.xz + +-----BEGIN PGP SIGNATURE----- + +iQKmBAEBCgCQFiEERkRAmAjBceBVMd3uBUy48xNDz0QFAlj3NzBfFIAAAAAALgAo +aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDQ2 +NDQ0MDk4MDhDMTcxRTA1NTMxRERFRTA1NENCOEYzMTM0M0NGNDQSHGNhcm5pbEBk +ZWJpYW4ub3JnAAoJEAVMuPMTQ89EacUP/jTn7xkMv9grOsGVVRWnvzQG+qBxl8qB +M3KzKS5Qug88GiCs0poJb0atA5GA9AQo9KznT5OcKDMAlPtx+AZuWTaP5GakKgBl +KJKeT2Evi7T+hQaI60OvGpLIeOEipnrBS3JH37rwn/OMcYbgL0IevfTN34oL45HX +YG0Y3DsRQzEDkLQZEm3cHieWXvjLsl2yWMWoB60dBSxHUH354BfdUOVWczfoVWYk +5U7/G4reQE3dIkYqvnFhbswli474WifnN93AObxN06QojNzYihNzHRhys5YEFAmU +lfmK6FdsCruCpsX8M6wOSTFZSEpPqvwDKAP89O4p3hmRGjmjq+1TqfeA1lfe5rKk +EA7cDb1Je4TrMtqq4WaY2uhcfoke0XkjufpYNqwMx6N2kn5nTN8f7xafrnCwOdWl +XxZx+EkOUNq7yBGNzgm9gSBgvpOdm7goug9n6bLq0i2RqaofymrT4NdFejPTfy0d +gFLs92LrYO/rZhY4/AJp1h5YCOJXay8A6hS2gI1ndd+tv7CooB3hNi922M6C5dnk +HIAcSEl+OOrcV7OU2RbBydJUbxqGiuXjWESkeWCEbtU+YAlBdtTORNMNXz9o0TS4 +AfrYvrc/1PnzsUmPM3gP5BXli5MExgIUTdPk3XD36xdrZQG9tI9VUBfPWaIkOQip +9ApzdObqiPZW +=Sh9M +-----END PGP SIGNATURE----- diff --git a/swh/loader/debian/tests/resources/hello_2.10.orig.tar.gz b/swh/loader/debian/tests/resources/hello_2.10.orig.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 GIT binary patch literal 0 Hc$@