Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add correct support for Reasons #10

Merged
merged 5 commits into from
Feb 26, 2023
Merged

Conversation

johlju
Copy link
Member

@johlju johlju commented Feb 26, 2023

Pull Request (PR) description

  • DscResource.Base
    • A new private function ConvertFrom-Reason was added which takes an
      array of [Reason] and coverts it to an array of [System.Collections.Hashtable].
    • The private function ConvertTo-Reason was renamed Resolve-Reason.
  • ResourceBase
    • The property Reasons in derived class-based resources is now expected
      to use the type [System.Collections.Hashtable[]] (issue #4).

This Pull Request (PR) fixes the following issues

Task list

  • Added an entry to the change log under the Unreleased section of the
    file CHANGELOG.md. Entry should say what was changed and how that
    affects users (if applicable), and reference the issue being resolved
    (if applicable).
  • Documentation added/updated in README.md.
  • Comment-based help added/updated for all new/changed functions.
  • Localization strings added/updated in all localization files as appropriate.
  • Examples appropriately added/updated.
  • Unit tests added/updated. See DSC Community Testing Guidelines.
  • Integration tests added/updated (where possible). See
    DSC Community Testing Guidelines.
  • New/changed code adheres to DSC Community Style Guidelines.

This change is Reviewable

@codecov
Copy link

codecov bot commented Feb 26, 2023

Codecov Report

Merging #10 (c7cbf7d) into main (0506f25) will increase coverage by 1%.
The diff coverage is 100%.

❗ Current head c7cbf7d differs from pull request most recent head 13e86e0. Consider uploading reports for the commit 13e86e0 to get more accurate results

Impacted file tree graph

@@        Coverage Diff         @@
##           main   #10   +/-   ##
==================================
+ Coverage    97%   99%   +1%     
==================================
  Files         6     7    +1     
  Lines       123   130    +7     
==================================
+ Hits        120   129    +9     
+ Misses        3     1    -2     
Flag Coverage Δ
unit 99% <100%> (+1%) ⬆️
Impacted Files Coverage Δ
source/Private/New-Reason.ps1 100% <ø> (ø)
source/Classes/010.ResourceBase.ps1 100% <100%> (+2%) ⬆️
source/Private/ConvertFrom-Reason.ps1 100% <100%> (ø)

Copy link
Member Author

@johlju johlju left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 3 of 9 files at r1, 6 of 6 files at r2, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @johlju)

@johlju johlju changed the title Add correct support for Reason Add correct support for Reasons Feb 26, 2023
Copy link
Member Author

@johlju johlju left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 5 of 5 files at r3, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @johlju)

@johlju johlju merged commit d97d1e1 into dsccommunity:main Feb 26, 2023
@johlju johlju deleted the fix/issue#4 branch February 26, 2023 12:25
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.

Using the property Reasons with type [Reason] fails if two modules have type [Reason]
1 participant