Skip to content

Add a few more user state dirs made by actual user creation in provision user helper#563

Open
jonasbardino wants to merge 1 commit into
nextfrom
adjust/unit-test-usersupp-to-include-more-actual-user-dirs-and-polish
Open

Add a few more user state dirs made by actual user creation in provision user helper#563
jonasbardino wants to merge 1 commit into
nextfrom
adjust/unit-test-usersupp-to-include-more-actual-user-dirs-and-polish

Conversation

@jonasbardino
Copy link
Copy Markdown
Contributor

Add a few more user state dirs made by actual user creation and importantly expected e.g. during useradm operations like edit_user, delete_user, etc. and therefore difficult to do without when adding test coverage a.o. in #561. Introduce two more common DNs used across tests: Other User and No Such User.
Polish a long comment with some typos and incomplete ending.

…tantly

expected e.g. during useradm operations like edit_user, delete_user, etc. and
therefore difficult to do without when adding test coverage a.o. in #561.
Introduce two more common DNs used across tests: Other User and No Such User.
Polish a long comment with some typos and incomplete ending.
@jonasbardino jonasbardino added the test-only Improvements or additions solely for better test coverage - without functionality changes label May 29, 2026
@jonasbardino jonasbardino marked this pull request as ready for review May 29, 2026 21:04
@albu-diku albu-diku self-requested a review June 4, 2026 08:52
Copy link
Copy Markdown
Contributor

@albu-diku albu-diku left a comment

Choose a reason for hiding this comment

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

That's a good place to do it I think - just double checked and the last set of changes in the area did unify on the ..._dirs function as I'd remembered.

Two ideas - it might be worth having a constant that lists which keys of users to loop over calling mkdir, the idea would be keep similarity with _USERADM_PATH_KEYS. The second is creating there directories unconditionally means a bunch of ensure_dirs_exist calls in the tests for the corresponding dirs are no longer needed and I wonder if it is worth cleaning those up here as well (mostly to save any confusion in the future).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test-only Improvements or additions solely for better test coverage - without functionality changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants