Skip to content

fix(tests): resolve sub-optimal test names and missing DKIM config exceptions#2001

Open
amlhive-tech wants to merge 1 commit into
maester365:mainfrom
amlhive-tech:fix/test-names-and-dkim-config
Open

fix(tests): resolve sub-optimal test names and missing DKIM config exceptions#2001
amlhive-tech wants to merge 1 commit into
maester365:mainfrom
amlhive-tech:fix/test-names-and-dkim-config

Conversation

@amlhive-tech

@amlhive-tech amlhive-tech commented Jul 25, 2026

Copy link
Copy Markdown

📑 Description

Fixes two open issues:

✅ Checks

  • My pull request adheres to the code style of this project.
  • My code requires changes to the documentation.
  • I have updated the documentation as required.
  • The build and unit tests pass locally.

Summary by CodeRabbit

  • Bug Fixes

    • Improved DKIM validation for accepted domains without a matching signing configuration.
    • Reports parked domains as skipped, Microsoft-managed domains as passed, and other unmatched domains as failed with clear reasons.
    • Prevents unnecessary selector rotation and DNS record checks when no signing configuration exists.
  • Documentation

    • Added a new contributor to the project registry.

@amlhive-tech
amlhive-tech requested review from a team as code owners July 25, 2026 13:02
@coderabbitai

coderabbitai Bot commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: ac4118d9-ad81-4401-94a7-5be3527f7dda

📥 Commits

Reviewing files that changed from the base of the PR and between f471f27 and 3d9aece.

📒 Files selected for processing (3)
  • powershell/public/cis/Test-MtCisDkim.ps1
  • powershell/public/cisa/exchange/Test-MtCisaDkim.ps1
  • website/contributors/contributors.yml
🚧 Files skipped from review as they are similar to previous changes (3)
  • powershell/public/cis/Test-MtCisDkim.ps1
  • website/contributors/contributors.yml
  • powershell/public/cisa/exchange/Test-MtCisaDkim.ps1

📝 Walkthrough

Walkthrough

The DKIM tests now handle accepted domains without matching signing configurations by recording explicit results and skipping DNS validation. Both function declarations lose their leading BOM, and the contributor registry adds an amlhive-tech entry.

Changes

DKIM handling

Layer / File(s) Summary
Handle missing DKIM configurations
powershell/public/cis/Test-MtCisDkim.ps1, powershell/public/cisa/exchange/Test-MtCisaDkim.ps1
Both functions remove leading BOM characters and record Skipped, Passed, or Failed results with reasons for domains lacking DKIM signing configurations before continuing past DNS validation.

Contributor registry

Layer / File(s) Summary
Add contributor metadata
website/contributors/contributors.yml
Adds the amlhive-tech contributor name, company, and email address.

Estimated code review effort: 2 (Simple) | ~10 minutes

Suggested reviewers: merill

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning Issue #1783 is addressed, but the summary shows no implementation of #1975's Common.Tests.ps1 test-name fix. Add the Common.Tests.ps1 test-name updates for #1975, or drop that issue reference if it is not included in this PR.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title matches the main changes by calling out test fixes and DKIM config handling.
Description check ✅ Passed The description includes a summary, linked issue references, checks, and extra context.
Out of Scope Changes check ✅ Passed The contributor entry is part of the stated PR objectives, and no unrelated changes are evident.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@merill merill left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hi @amlhive-tech thanks for your PR!

Can I ask you split this into two PRs please?

This will make it easier to track unrelated changes.

For the pester update we are currently pinned to 5.x and not Pester 6, so the rename of the tests as as will not be accurate. We might need to do this as a seperate PR that moves everything to Pester 6 in one go.

@amlhive-tech
amlhive-tech force-pushed the fix/test-names-and-dkim-config branch from f471f27 to 3d9aece Compare July 25, 2026 22:48
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 this pull request may close these issues.

Sub-optimal test names in Pester tests Test-MtCisDkim and Test-MtCisaDkim crash when accepted domain has no DkimSigningConfig

2 participants