Skip to content

tests: new nightly workflow to check test snaps - #17844

Open
sergiocazzolato wants to merge 1 commit into
canonical:masterfrom
sergiocazzolato:tests-check-test-snaps
Open

sergiocazzolato wants to merge 1 commit into
canonical:masterfrom
sergiocazzolato:tests-check-test-snaps

Conversation

@sergiocazzolato

Copy link
Copy Markdown
Contributor

This nightly workflow checks if there are new test snaps which need to be registered under canonical account. Also check if test snaps have to be saved under tests/lib/snaps/store

This nightly workflow checks if there are new test snaps which need to
be registered under canonical account. Also check if test snaps have to
be saved under tests/lib/snaps/store

@maykathm maykathm left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice

path: current/test-snaps.json
retention-days: 7

- name: Download previous inventory

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldn't this go before "Upload current inventory" to avoid a race? are we sure workflow_runs[0] will always be the previous run?

if snap["classification"] == store_classification and not belongs_to_canonical:
errors.append(f"{name}: store fixture is published by {publisher!r}")

if name.startswith("test-snapd-") and snap["classification"] == external_classification:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some test snaps don't start with test-snapd-*, some only start with test-*

Suggested change
if name.startswith("test-snapd-") and snap["classification"] == external_classification:
if name.startswith("test-") and snap["classification"] == external_classification:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can add exceptions if we get false positives with the broader filter

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants