Skip to content

Hardening SDK testing#6

Merged
josesimoes merged 7 commits into
mainfrom
hardening-tests
Jun 24, 2026
Merged

Hardening SDK testing#6
josesimoes merged 7 commits into
mainfrom
hardening-tests

Conversation

@josesimoes

Copy link
Copy Markdown
Member

Description

  • Add new task in AZDO to build using msbuild task.
  • Add PS1 to compare nanoresources hash between net472 <--> net8.0 builds.

Motivation and Context

How Has This Been Tested?

Screenshots

Types of changes

  • Improvement (non-breaking change that improves a feature, code or algorithm)
  • Bug fix (non-breaking change which fixes an issue with code or algorithm)
  • New feature (non-breaking change which adds functionality to code)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Config and build (change in the configuration and build system, has no impact on code or features)
  • Dependencies (update dependencies and changes associated, has no impact on code or features)
  • Unit Tests (add new Unit Test(s) or improved existing one(s), has no impact on code or features)
  • Documentation (changes or updates in the documentation, has no impact on code or features)

Checklist:

  • My code follows the code style of this project (only if there are changes in source code).
  • My changes require an update to the documentation (there are changes that require the docs website to be updated).
  • I have updated the documentation accordingly (the changes require an update on the docs in this repo).
  • I have read the CONTRIBUTING document.
  • I have tested everything locally and all new and existing tests passed (only if there are changes in source code).
  • I have added new tests to cover my changes.

@coderabbitai

coderabbitai Bot commented Jun 24, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@josesimoes, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 40 minutes and 10 seconds. Learn how PR review limits work.

Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file).

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits.

🚦 How do rate limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: nanoframework/coderabbit/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 32edd5ab-24db-4878-a9b4-12ea644c1597

📥 Commits

Reviewing files that changed from the base of the PR and between 3a55c9a and 7d499cb.

📒 Files selected for processing (1)
  • azure-pipelines.yml
📝 Walkthrough

Walkthrough

The pipeline adds a SmokeTest parity check, rebuilds SmokeTest with both dotnet and MSBuild, and updates versioning settings in version.json.

Changes

SmokeTest parity validation and versioning

Layer / File(s) Summary
Packaging and versioning
azure-pipelines.yml, version.json
The pack task gains a success condition, and version.json adds pull-request merge refs plus nested cloud build number settings.
SmokeTest pipeline steps
azure-pipelines.yml
The SmokeTest job renames the dotnet build step, adds a VSBuild@1 build of SmokeTest.csproj, and invokes the parity script with the build configuration.
Parity script
test/SmokeTest/Verify-Parity.ps1
The new PowerShell script resolves the project and MSBuild toolchain, builds net8.0 and net472, captures .nanoresources outputs, compares file names and SHA256 hashes, and cleans up temporary files.

Sequence Diagram(s)

sequenceDiagram
  participant AzurePipelines
  participant VSBuildTask
  participant PowerShellTask
  participant VerifyParity as Verify-Parity.ps1
  participant DotNetBuild as dotnet build
  participant MSBuildExe as msbuild.exe
  AzurePipelines->>VSBuildTask: build SmokeTest.csproj with /p:Restore=false
  AzurePipelines->>PowerShellTask: run Verify-Parity.ps1 -Configuration $(buildConfiguration)
  PowerShellTask->>VerifyParity: invoke script
  VerifyParity->>DotNetBuild: build net8.0 and capture .nanoresources
  VerifyParity->>MSBuildExe: build net472 and capture .nanoresources
  VerifyParity->>VerifyParity: compare file names and SHA256 hashes
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title concisely reflects the PR’s build and test hardening changes.
Description check ✅ Passed The description matches the Azure DevOps build task and parity-check script changes.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


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.

- Add new task in AZDO to build using msbuild task.
- Add PS1 to compare nanoresources hash between net472 <--> net8.0 builds.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@test/SmokeTest/Verify-Parity.ps1`:
- Line 63: The Verify-Parity.ps1 script hardcodes the intermediate output folder
via the resourceDirectory assignment, which ties it to a specific TFM. Update
the logic to query MSBuild for IntermediateOutputPath (or an equivalent
evaluated property) instead of composing obj\<BuildConfiguration>\netnano1.0,
and keep the change localized to the resourceDirectory setup so the script works
across target frameworks.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: nanoframework/coderabbit/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: be338f1e-b4b6-4986-80da-7e6774b8fa01

📥 Commits

Reviewing files that changed from the base of the PR and between 36f40d6 and 0ec6ca7.

📒 Files selected for processing (2)
  • azure-pipelines.yml
  • test/SmokeTest/Verify-Parity.ps1

Comment thread test/SmokeTest/Verify-Parity.ps1

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@test/SmokeTest/Verify-Parity.ps1`:
- Around line 83-88: The parity check in Verify-Parity.ps1 should stop treating
a non-zero toolchain exit as recoverable just because .nanoresources were
generated. Update the conditional around the build result so that Verify-Parity
always fails on any non-zero exit from the toolchain build, and remove the
warning/continue path tied to $resourceFiles.Count in that branch. Keep the
failure behavior centered on the exitCode handling in the build check.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: nanoframework/coderabbit/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: d3417a5b-d771-40aa-997f-16b660e8d5e8

📥 Commits

Reviewing files that changed from the base of the PR and between 0ec6ca7 and ba270e8.

📒 Files selected for processing (2)
  • azure-pipelines.yml
  • test/SmokeTest/Verify-Parity.ps1

Comment thread test/SmokeTest/Verify-Parity.ps1 Outdated
@josesimoes josesimoes force-pushed the hardening-tests branch 2 times, most recently from 12d63a1 to a446fae Compare June 24, 2026 21:31
@josesimoes josesimoes merged commit def0da5 into main Jun 24, 2026
4 checks passed
@josesimoes josesimoes deleted the hardening-tests branch June 24, 2026 22: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.

2 participants