Skip to content

Added a check in the job "test-store-config" for missing store field (BugFix)#1664

Merged
Hook25 merged 2 commits intomainfrom
store-check-added-for-model-resource
Dec 19, 2024
Merged

Added a check in the job "test-store-config" for missing store field (BugFix)#1664
Hook25 merged 2 commits intomainfrom
store-check-added-for-model-resource

Conversation

@fernando79513
Copy link
Copy Markdown
Collaborator

Description

With the new template checks, we discovered an error with the "snappy/test-store-config-store" test. The test was trying to be created even if no store was declared.

CategorySnapdIO LogTemplate 'com.canonical.certification::snappy/test-store-config-store' generated an invalid unit. Field 'command' has value 'echo "Expected store ID:"
echo "$STORE_ID"
echo
echo "Store ID in model assertion:"
echo "{store}"
[ "$STORE_ID" == "{store}" ]' but the template-resource didn't generate any value for 'store'

Now we set the store field in the "model_resource" to "unknown" and filter that in the templated test

Resolved issues

#1663

N/A

Documentation

Tests

After running a reduced version of the snappy automated tests, the test-store-config test is not templated anymore

@codecov
Copy link
Copy Markdown

codecov bot commented Dec 19, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 48.99%. Comparing base (f6f1b9b) to head (f1e78e5).
Report is 92 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1664   +/-   ##
=======================================
  Coverage   48.99%   48.99%           
=======================================
  Files         372      372           
  Lines       40319    40321    +2     
  Branches     6810     6811    +1     
=======================================
+ Hits        19755    19757    +2     
  Misses      19842    19842           
  Partials      722      722           
Flag Coverage Δ
checkbox-support ∅ <100.00%> (∅)
provider-base 24.79% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Hook25
Hook25 previously approved these changes Dec 19, 2024
Copy link
Copy Markdown
Collaborator

@Hook25 Hook25 left a comment

Choose a reason for hiding this comment

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

tyvm for fixing this! +1

@Hook25 Hook25 merged commit 4305ba1 into main Dec 19, 2024
@Hook25 Hook25 deleted the store-check-added-for-model-resource branch December 19, 2024 16:38
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.

2 participants