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

Parametrize sssctl tests 2. #7802

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dkarpele
Copy link
Contributor

@dkarpele dkarpele commented Jan 18, 2025

  • Combine various sssctl tests to the single parametrized tests.

test_sssctl__check_invalid_section_name merges tests:

test_sssctl__check_missing_equal_sign
test_sssctl__check_invalid_id_provider
test_sssctl__check_missing_id_provider
test_sssctl__check_special_character_in_option_name test_sssctl__check_special_character_in_section_name test_sssctl__check_special_character_in_domain_name test_sssctl__check_forward_slash_missing_in_domain_section test_sssctl__check_invalid_sssd_section_name
test_sssctl__check_missing_closing_bracket
test_sssctl__check_missing_opening_bracket

Drop tests:
test_sssctl__check_invalid_pam_section_name (duplicate test_sssctl__check_invalid_sssd_section_name)
test_sssctl__check_invalid_nss_section_name (duplicate test_sssctl__check_invalid_sssd_section_name)

Copy link

@danlavu danlavu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG2M

@dkarpele dkarpele force-pushed the dkarpele-param-sssctl-2 branch from 501812c to d2ae521 Compare January 23, 2025 17:32
:expectedresults:
1. config-check detects an error
2. Error messages are properly set
1. sssctl configuration check fails with the correct output in stdout
:customerscenario: False
"""
client.sssd.common.local()
client.sssd.start()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still think no 'sssctl.config_check' tests need to start SSSD.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Explicit apply-config is better (from "intention" point of view) and faster.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree. But let's do it in the separate PR because it's not related with parametrization and all tests in this module should be updated.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@dkarpele dkarpele force-pushed the dkarpele-param-sssctl-2 branch from d2ae521 to 14509ce Compare January 25, 2025 15:56
- Combine various sssctl tests to the single parametrized tests.

test_sssctl__check_invalid_semantic_in_section_name merges tests:

test_sssctl__check_missing_id_provider
test_sssctl__check_invalid_id_provider
test_sssctl__check_special_character_in_option_name
test_sssctl__check_special_character_in_domain_name
test_sssctl__check_invalid_sssd_section_name

test_sssctl__check_invalid_syntax_in_section_name merges tests:

test_sssctl__check_missing_equal_sign
test_sssctl__check_missing_closing_bracket
test_sssctl__check_missing_opening_bracket

Dropped tests:
test_sssctl__check_special_character_in_section_name
test_sssctl__check_forward_slash_missing_in_domain_section
test_sssctl__check_invalid_pam_section_name
test_sssctl__check_invalid_nss_section_name

Signed-off-by: Denis Karpelevich <dkarpele@redhat.com>
@dkarpele dkarpele force-pushed the dkarpele-param-sssctl-2 branch from 14509ce to 8ebc88d Compare January 31, 2025 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants