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

ActiveDirectoryDsc: Migrate HQRM And Unit Tests to PowerShell 7 #597

Merged
merged 16 commits into from
Apr 21, 2020

Conversation

X-Guardian
Copy link
Contributor

@X-Guardian X-Guardian commented Apr 17, 2020

Pull Request (PR) description

This PR migrates the HQRM and Unit Tests to using PowerShell 7 in the CI. This is to avoid this PowerShell performance issue with Pester: pester/Pester#1318.
This reduces the runtime of the Unit Tests in the CI from 45 minutes to 10 minutes.

Changes that had to be made as part of this:

  • New function Get-ByteContent used by the ADUser resource Get-ThumbnailByteArray function to cope with different Get-Content parameters between PowerShell Desktop and Core.
  • Compare-ResourcePropertyState test changes to handle differences between PowerShell Desktop And Core with hashtable ordering.
  • ActiveDirectory stub module changes due to PowerShell Core unimplemented SecurityIdentifier property of the System.Security.Principal class.
  • Implementation of a stub module for Kds as this module will not currently import on PowerShell Core.

This Pull Request (PR) fixes the following issues

None

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).
  • Resource documentation added/updated in README.md.
  • Resource parameter descriptions added/updated in README.md, schema.mof
    and comment-based help.
  • Comment-based help added/updated.
  • 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

@johlju johlju added the waiting for author response The pull request is waiting for the author to respond to comments in the pull request. label Apr 19, 2020
@X-Guardian X-Guardian changed the title ActiveDirectoryDsc: HQRM And Unit Tests - PowerShell 7 Test ActiveDirectoryDsc: Migrate HQRM And Unit Tests to PowerShell 7 Apr 19, 2020
@X-Guardian X-Guardian marked this pull request as ready for review April 19, 2020 19:29
@X-Guardian X-Guardian added the needs review The pull request needs a code review. label Apr 19, 2020
@X-Guardian X-Guardian requested a review from johlju April 19, 2020 19:29
@X-Guardian X-Guardian removed the waiting for author response The pull request is waiting for the author to respond to comments in the pull request. label Apr 19, 2020
Copy link
Member

@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 11 of 11 files at r1.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

@johlju
Copy link
Member

johlju commented Apr 21, 2020

@X-Guardian Awesome work! 😄

@johlju johlju added ready for merge The pull request was approved by the community and is ready to be merged by a maintainer. and removed needs review The pull request needs a code review. labels Apr 21, 2020
@johlju johlju merged commit 78b9c56 into dsccommunity:master Apr 21, 2020
@johlju johlju removed the ready for merge The pull request was approved by the community and is ready to be merged by a maintainer. label Apr 21, 2020
@X-Guardian X-Guardian deleted the PowerShell-7-Test branch April 25, 2020 11:01
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.

2 participants