goss-org / goss

Quick and Easy server testing/validation
https://goss.rocks
Apache License 2.0
5.53k stars 470 forks source link

Support querying snap packages #779

Closed nbirnel closed 1 year ago

nbirnel commented 1 year ago

Describe the feature:

Support for snap packages.

Describe the solution you'd like

snap would be added to the valid package types for the --package option.

goss --package snap add package certbot

Describe alternatives you've considered

Something like this works:

command:
  certbot-installed-with-snap:
    exit-status: 0
    exec: snap list certbot | grep '^certbot\s' >/dev/null

but is, in my opinion, less clear.

aelsabbahy commented 1 year ago

Hello, and thank you for opening this feature request.

Unfortunately, due to the maintenance burden it would introduce, anything outside of the core system package managers (example: rpm, apt) is not supported natively by Goss.

Command is your best best here. That said, if there are ways that the command test type can be enhanced to improve the user experience, please feel free to open enhancement requests for that.