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

Test suite does not correctly test non auth mode #3102

Open
schandrika opened this issue Aug 17, 2023 · 0 comments · Fixed by #3107
Open

Test suite does not correctly test non auth mode #3102

schandrika opened this issue Aug 17, 2023 · 0 comments · Fixed by #3107
Assignees

Comments

@schandrika
Copy link
Contributor

platformwrapper and volttron_platform_fixtures are used by all integration tests in volttron. These set up the volttron environment and instance. Both need to be fixed for testing volttron server in non auth mode. i.e. when authentication and authorization is disabled.

Issues:

  1. volttron_platform_fixture uses pytest's request.param.pop() method to get value of variables that are parameterized for a fixture. This however does not correctly return the value set for the boolean variable, auth_enabled. When auth_enabled is set to False, request.param.pop('auth_enabled', True) always returns True. This would lead all tests to always run with auth_enabled=True. pytest's request.param is a object that acts similar to python's dictionary object, however the pop method doesn't return value similar to that of a dictionary object. Fix - use request.param.get instead of request.param.pop

  2. platformwrapper generate keystore and server key even when auth is disabled.

@schandrika schandrika self-assigned this Aug 17, 2023
schandrika added a commit to schandrika/volttron that referenced this issue Aug 18, 2023
schandrika added a commit to schandrika/volttron that referenced this issue Aug 18, 2023
schandrika added a commit to schandrika/volttron that referenced this issue Aug 18, 2023
…r instance so that both auth and non auth mode are tested
@craig8 craig8 linked a pull request Aug 18, 2023 that will close this issue
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 a pull request may close this issue.

1 participant