flathub / com.synology.SynologyDrive

https://flathub.org/apps/details/com.synology.SynologyDrive
7 stars 10 forks source link

Add sha test ci #40

Closed lil5 closed 7 months ago

lil5 commented 7 months ago

This tests if the metadata corresponds with the deb file.

      - type: extra-data
        filename: synology-drive.deb
        only-arches: [x86_64]
        url: https://global.synologydownload.com/download/Utility/SynologyDriveClient/3.3.0-15082/Ubuntu/Installer/x86_64/synology-drive-client-15082.x86_64.deb
        sha256: 85adca4691084fbc3aa54554c19574d755b517fbff84dabd7f702b7f35346467
        size: 101062840
  1. Reads the yaml file
  2. Downloads the deb
  3. Checks the file size
  4. Checks the file sha256

To run this for your self run:

cd tests
pipenv install
pipenv run pytest
flathubbot commented 7 months ago

Started test build 86563

flathubbot commented 7 months ago

Build 86563 successful To test this build, install it from the testing repository:

flatpak install --user https://dl.flathub.org/build-repo/69223/com.synology.SynologyDrive.flatpakref
RayJW commented 7 months ago

I like the idea of this, but is there anything that does that the Flathub Bot doesn't already check? Since we specify the size and sha sum of the file that is being downloaded, the bot already checks for file corruption before continuing the build. T only thing this would verify, is that the Flathub Bot is compromised, in which case we have other issues anyway, no?

lil5 commented 7 months ago

If that's indeed the case for the flathub bot, yes it's not necessary my bad.

flathubbot commented 7 months ago

I'm sorry, i did not understand that command.