Skip to content

Migrate the IAM PasswordPolicy tests#13771

Open
pinzon wants to merge 1 commit intoiam/moto-migrationfrom
cris/unc-223
Open

Migrate the IAM PasswordPolicy tests#13771
pinzon wants to merge 1 commit intoiam/moto-migrationfrom
cris/unc-223

Conversation

@pinzon
Copy link
Member

@pinzon pinzon commented Feb 13, 2026

Motivation

For internalization of the IAM service. This PR migrates the IAM service tests related to the PasswordPolicy feature from the moto library.

Changes

Source

File: moto/tests/test_iam/test_iam.py

Destination

File: localstack/tests/aws/services/iam/test_iam_account_password_policy.py

Test Mapping

# Moto Test Line LocalStack Test Description
1 test_update_account_password_policy 3381 test_update_account_password_policy_defaults Tests update with default parameter values
2 test_update_account_password_policy_errors 3401 test_update_account_password_policy_validation_errors Tests validation constraints for invalid values
3 test_get_account_password_policy 3416 test_update_account_password_policy_custom_values Tests update with all custom parameters and retrieval
4 test_get_account_password_policy_errors 3447 test_get_account_password_policy_not_found Tests NoSuchEntity error when policy missing
5 test_delete_account_password_policy 3460 test_delete_account_password_policy Tests delete workflow and verification
6 test_delete_account_password_policy_errors 3644 test_delete_account_password_policy_not_found Tests error when deleting non-existent policy

Consolidations

  • test_get_account_password_policy was removed as redundant — its functionality (retrieving a policy with custom values) is already covered by test_update_account_password_policy_custom_values.

API Operations Covered

Operation Tests
UpdateAccountPasswordPolicy 3 tests
GetAccountPasswordPolicy 1 test
DeleteAccountPasswordPolicy 2 tests

@pinzon pinzon added semver: patch Non-breaking changes which can be included in patch releases docs: skip Pull request does not require documentation changes notes: skip Pull request does not have to be mentioned in the release notes labels Feb 13, 2026
@pinzon pinzon marked this pull request as ready for review February 13, 2026 19:01
@pinzon pinzon requested a review from dfangl as a code owner February 13, 2026 19:01
@github-actions
Copy link

Test Results - Preflight, Unit

23 099 tests   - 12   21 237 ✅  - 12   6m 37s ⏱️ +22s
     1 suites ± 0    1 862 💤 ± 0 
     1 files   ± 0        0 ❌ ± 0 

Results for commit 5ba4fb5. ± Comparison against base commit cdcd4df.

@github-actions
Copy link

LocalStack Community integration with Pro

  2 files  ±    0    2 suites  ±0   1m 2s ⏱️ - 2h 3m 9s
423 tests  - 5 011  221 ✅  - 4 663  202 💤  - 348  0 ❌ ±0 
425 runs   - 5 011  221 ✅  - 4 663  204 💤  - 348  0 ❌ ±0 

Results for commit 5ba4fb5. ± Comparison against base commit cdcd4df.

@github-actions
Copy link

Test Results (amd64) - Acceptance

7 tests  ±0   5 ✅ ±0   3m 6s ⏱️ +5s
1 suites ±0   2 💤 ±0 
1 files   ±0   0 ❌ ±0 

Results for commit 5ba4fb5. ± Comparison against base commit cdcd4df.

@github-actions
Copy link

Test Results (amd64) - Integration, Bootstrap

  5 files  ±    0    5 suites  ±0   9m 53s ⏱️ - 2h 29m 24s
447 tests  - 5 392  245 ✅  - 4 888  202 💤  - 504  0 ❌ ±0 
453 runs   - 5 392  245 ✅  - 4 888  208 💤  - 504  0 ❌ ±0 

Results for commit 5ba4fb5. ± Comparison against base commit cdcd4df.

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

Labels

docs: skip Pull request does not require documentation changes notes: skip Pull request does not have to be mentioned in the release notes semver: patch Non-breaking changes which can be included in patch releases

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant