Skip to content
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

Unit Tests for SecurityHub-alarms module in Baselines #7309

Closed
3 tasks done
richgreen-moj opened this issue Jun 24, 2024 · 3 comments
Closed
3 tasks done

Unit Tests for SecurityHub-alarms module in Baselines #7309

richgreen-moj opened this issue Jun 24, 2024 · 3 comments
Assignees

Comments

@richgreen-moj
Copy link
Contributor

richgreen-moj commented Jun 24, 2024

User Story

As a MP Engineer
I need to write some unit tests for the SecurityHub-alarms sub-module in the Baselines module
So that I can increase the confidence in the modules

Value / Purpose

As a follow-on from #6490 this ticket is to add missing unit tests for some of the sub-modules in the MP Baselines module.

Useful Contacts

@richgreen-moj

Additional Information

No response

Proposal / Unknowns

No response

Definition of Done

  • Missing unit tests added
  • New unit tests pass
  • Another team member has reviewed
@richgreen-moj
Copy link
Contributor Author

@richgreen-moj
Copy link
Contributor Author

richgreen-moj commented Aug 13, 2024

Unit tests added for the securityhub-alarms module. The main changes to the underlying module is just adding in variables for all the resource names so that they are not duplicated when running the unit tests. These are then all defaulted to the original values so that it won't affect accounts with baseline resources already built.

I've also had to add some outputs to facilitate the testing and have added a new TestTerraformSecurityHubAlarms testing function in the baselines_test.go file

@richgreen-moj
Copy link
Contributor Author

New version of the baselines module has been released v7.6.3 and this has now been deployed via #7684

@richgreen-moj richgreen-moj moved this from In Progress to For Review in Modernisation Platform Aug 15, 2024
@dms1981 dms1981 moved this from For Review to Done in Modernisation Platform Aug 15, 2024
@dms1981 dms1981 closed this as completed by moving to Done in Modernisation Platform Aug 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

No branches or pull requests

3 participants