-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes 2941: Add RpmRepositoryVersionErrataList to tangy #6
Conversation
func (r *RpmSuite) CreateTestRepositoryWithErrata(t *testing.T) { | ||
_, err := r.client.LookupOrCreateDomain(r.domainName) | ||
require.NoError(t, err) | ||
|
||
repoHref, remoteHref, err := r.client.CreateRepository(r.domainName, testRepoNameWithErrata, testRepoWithErrata) | ||
require.NoError(t, err) | ||
|
||
syncTask, err := r.client.SyncRpmRepository(repoHref, remoteHref) | ||
require.NoError(t, err) | ||
|
||
_, err = r.client.PollTask(syncTask) | ||
require.NoError(t, err) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you refactor this to update the existing "CreateTestRepository" method to take a name and URL as input? Then we can use that method for any repository creation.
@@ -244,6 +262,49 @@ func (r *RpmSuite) TestRpmRepositoryVersionEnvironmentSearch() { | |||
assert.Len(r.T(), search, 0) | |||
} | |||
|
|||
func (r *RpmSuite) TestRpmRepositoryVersionErrataListFilter() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you also add some cases to make sure that limit and offset are working?
i haven't found a repo with packages that include severities in the errata, so i haven't been able to really test that filter yet here. i've verified it works with the backend and UI, but if you know of any repos i could use to test here let me know |
Hi, this repo has severity: |
@swadeley do the package errata in that repo have an updatedDate? trying to view that repo's package errata has surfaced an error: these are the values expected and i'm just assuming updatedDate is missing since it's the 7th one: if updatedDate can be null (which makes sense if it can), i'll need to add a change |
ok, changed updatedDate to *string and can now view the errata. thanks again |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good! remember to do the release after you merge!
Adds a function to list errata in repository versions, supports pagination and filtering on errata id, type, and severity
Can be tested with this backend PR