middleware
middleware copied to clipboard
NAS-129260 / 24.10 / Replace shareuser with UserAssets.ShareUser01 in depends
During PR #13491 the following:
@pytest.mark.dependency(name="shareuser")
def test_27_creating_shareuser_to_test_sharing(request):
was replaced with
@pytest.mark.dependency(name=UserAssets.ShareUser01['depends_name'])
def test_020_create_and_verify_shareuser():
However, dependent changes were only made in test_011_user.py, e.g.
def test_038_change_homedir_to_existing_path(request):
depends(request, [UserAssets.ShareUser01['depends_name'], UserAssets.TestUser01['depends_name']])
....
(Note that the actual string referred to by depends_name has changed to "share_user_01")
This PR updates a couple of other tests in different modules that also depend on "shareuser". Also did some tidy/flake8 fixes.
Before this PR they were being skipped. (PR tested in CI run 550)
Question: worth backporting to 24.04.2 ?
Jira URL: https://ixsystems.atlassian.net/browse/NAS-129260
Handled in https://github.com/truenas/middleware/pull/13987