phac-nml / irida-next

IRIDA Next
https://phac-nml.github.io/irida-next/
Apache License 2.0
8 stars 2 forks source link

[DFCT0010089] Fix groups being able to recursively share to themselves #649

Closed JeffreyThiessen closed 2 weeks ago

JeffreyThiessen commented 2 weeks ago

What does this PR do and why?

Fixes #642

Fixes bug where a group could be shared with itself.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other pull requests.

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Sign in with a non admin user
  2. Create a new group
  3. Select Members on sidebar, then select Groups tab, then click Invite Group
  4. In the Group to share namespace with dropdown, see that the current group is not in the list of groups.

PR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

JeffreyThiessen commented 2 weeks ago

Can I get you to also add tests for the group_link_service_test to ensure that a group cannot be linked to itself

Fixed in https://github.com/phac-nml/irida-next/pull/649/commits/492cd9cbbeff759c33816d92c4ad6b73a73f48a5

github-actions[bot] commented 2 weeks ago

Simplecov Report

Covered Threshold
92.45% 90%