Move Security Reports logic to its own widget
What does this MR do and why?
This is a small refactoring that moves the internal logic inside the Widget itself.
Screenshots or screen recordings
No visual changes
How to set up and validate locally
There are three steps to validate this.
- Fork https://gitlab.com/gitlab-examples/security/security-reports/ (make sure that it's public, we're gonna need it)
- Make sure to have an EE license
- Create an MR by modifying the Readme.md file
It should display the Security Reports details similar to this:
Now, open an Incognito Tab and visit the same page. It should display the CE version (because canReadVulnerabilities
is false
):
Now, create a project that has no Security Reports enabled. Follow the same steps and create an MR. It should look like this:
This is because the user can actually read the vulnerabilities, but the project has no enabledReports
.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #414464 (closed)