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

Update unit tests' mock auth objects to use auto-speccing #215

Merged

Conversation

hur
Copy link
Collaborator

@hur hur commented Oct 17, 2024

Update unit tests' mock auth objects to use auto-speccing

  • Enhancement
  • Major feature update
  • Bug fixes
  • Breaking change
  • Updated unit tests
  • Documentation

Check the values above that match your PR and remove the remaining.

Bandit analysis

(caracara-py3.11) USER-REDACTED@HOSTNAME-REDACTED tests % bandit -r . --configfile=.bandit
[main]	INFO	Found project level .bandit file: ./.bandit
[utils]	WARNING	Unable to parse config file ./.bandit or missing [bandit] section
[main]	INFO	profile include tests: None
[main]	INFO	profile exclude tests: B101
[main]	INFO	cli include tests: None
[main]	INFO	cli exclude tests: None
[main]	INFO	using config: .bandit
[main]	INFO	running on Python 3.11.9
Run started:2024-10-17 14:55:08.937788

Test results:
	No issues identified.

Code scanned:
	Total lines of code: 1445
	Total lines skipped (#nosec): 0

Run metrics:
	Total issues (by severity):
		Undefined: 0
		Low: 0
		Medium: 0
		High: 0
	Total issues (by confidence):
		Undefined: 0
		Low: 0
		Medium: 0
		High: 0
Files skipped (0):

Added features and functionality

Fixed an issue with executing unit tests

Issues resolved

Other

@hur
Copy link
Collaborator Author

hur commented Oct 17, 2024

Note: 9 unit tests won't pass, these should probably be fixed in a separate issue / PR ?

FAILED tests/unit_tests/test_custom_ioas.py::test_describe_rule_groups_with_rules - AssertionError: assert {'comment': '...000000Z', ...} == {'comment': '...000000Z', ...}
FAILED tests/unit_tests/test_custom_ioas.py::test_update_rule_groups_with_rule_changes - assert 1 == (1 + 1)
FAILED tests/unit_tests/test_hosts.py::test_contain - caracara.common.exceptions.MustProvideFilter: [500] You must provide a Falcon Filter in order to use this method
FAILED tests/unit_tests/test_hosts.py::test_release - caracara.common.exceptions.MustProvideFilter: [500] You must provide a Falcon Filter in order to use this method
FAILED tests/unit_tests/test_hosts.py::test_hide - caracara.common.exceptions.MustProvideFilter: [500] You must provide a Falcon Filter in order to use this method
FAILED tests/unit_tests/test_hosts.py::test_unhide - caracara.common.exceptions.MustProvideFilter: [500] You must provide a Falcon Filter in order to use this method
FAILED tests/unit_tests/test_hosts.py::test_tag - caracara.common.exceptions.MustProvideFilter: [500] You must provide a Falcon Filter in order to use this method
FAILED tests/unit_tests/test_hosts.py::test_untag - caracara.common.exceptions.MustProvideFilter: [500] You must provide a Falcon Filter in order to use this method
FAILED tests/unit_tests/test_prevention_policies.py::test_push_policy - TypeError: 'NoneType' object is not iterable

@ChristopherHammond13 ChristopherHammond13 merged commit abf35eb into CrowdStrike:main Oct 17, 2024
8 checks passed
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.

[ BUG ] Unit tests fail to run
2 participants