Skip to content
This repository was archived by the owner on Jun 13, 2024. It is now read-only.

Commit 73e6f87

Browse files
johljualerickson
authored andcommitted
Updated CI pipeline for testing PSModule DSC resources (#413)
1 parent 3f6f735 commit 73e6f87

17 files changed

+2595
-177
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -269,3 +269,7 @@ FakesAssemblies/
269269
*.xproj
270270
*.xproj.user
271271
*.suo
272+
273+
# Ignore DscResource.Tests repository when it is cloned
274+
# when running DSC resource unit tests locally.
275+
DSC/DscResource.Tests

CHANGELOG.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,34 @@
11
# Changelog
2+
3+
## Unreleased
4+
5+
* Update the AppVeyor CI test pipeline with a new job to run tests for
6+
the DSC resources, primarily for the resource `PSModule`.
7+
The new job uses the test framework used for the DSC Resource Kit,
8+
the [DscResource.Tests](https://github.com/PowerShell/DscResource.Tests) repository.
9+
* Update .gitignore to ignore the [DscResource.Tests](https://github.com/PowerShell/DscResource.Tests)
10+
test framework. When running unit test locally it is cloned into the
11+
local repository folder.
12+
* Added module PowerShellGet.LocalizationHelper containing localization
13+
helper functions for DSC resources, and unit tests for the helper
14+
functions.
15+
* Moved helper functions for the DSC resource `PSModule` to the module
16+
PowerShellGet.ResourceHelper. Added improved localization support, and
17+
code formatting against workspace VS Code settings.
18+
* Changes to PSModule.
19+
* Added improved localization support.
20+
* Changed type on the parameters that had `[Switch]` to correctly use
21+
`Systen.Boolean` to match the schema.mof.
22+
* Code formatting against workspace VS Code settings.
23+
* Added unit tests.
24+
* Added integration tests
25+
* It is now possible to install a module and passing in `AllowClobber`
26+
when the modules package source is trusted (it already worked in
27+
other scenarios).
28+
* Changed the AppVeyor CI build pipeline so it added the DSC resource
29+
`PSModule` and dependent helper modules (the `Modules` folder) to the
30+
AppVeyor artifact.
31+
232
## 2.0.4
333
Bug Fix
434
* Remove PSGallery availability checks (#374)

DSC/DSC.psd1

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
<#
2+
This is a dummy PowerShell manifest file so that the DscResource.Tests
3+
test framework recognize the module folder as correct (expected) folder
4+
and file structure.
5+
THIS FILE IS NOT USE DURING DEPLOYMENT.
6+
#>
7+
@{
8+
# Version number of this module.
9+
moduleVersion = '0.0.0.1'
10+
11+
# ID used to uniquely identify this module
12+
GUID = 'e102ebd2-bdc3-4d0f-bc93-4b8cc3eb7074'
13+
14+
# Author of this module
15+
Author = 'Microsoft Corporation'
16+
17+
# Company or vendor of this module
18+
CompanyName = 'Microsoft Corporation'
19+
20+
# Copyright statement for this module
21+
Copyright = '(c) 2019 Microsoft Corporation. All rights reserved.'
22+
23+
# Description of the functionality provided by this module
24+
Description = 'Module with DSC Resources for deployment of PowerShell modules.'
25+
26+
# Minimum version of the Windows PowerShell engine required by this module
27+
PowerShellVersion = '5.0'
28+
29+
# Minimum version of the common language runtime (CLR) required by this module
30+
CLRVersion = '4.0'
31+
32+
# Functions to export from this module
33+
FunctionsToExport = @()
34+
35+
# Cmdlets to export from this module
36+
CmdletsToExport = @()
37+
38+
RequiredAssemblies = @()
39+
40+
<#
41+
Private data to pass to the module specified in RootModule/ModuleToProcess.
42+
This may also contain a PSData hashtable with additional module metadata used by PowerShell.
43+
#>
44+
PrivateData = @{
45+
46+
PSData = @{
47+
48+
# Tags applied to this module. These help with module discovery in online galleries.
49+
Tags = @('DesiredStateConfiguration', 'DSC', 'DSCResource')
50+
51+
# A URL to the license for this module.
52+
LicenseUri = 'https://github.com/PowerShell/PowerShellGet/blob/master/LICENSE'
53+
54+
# A URL to the main website for this project.
55+
ProjectUri = 'https://github.com/PowerShell/PowerShellGet'
56+
57+
# ReleaseNotes of this module
58+
ReleaseNotes = ''
59+
60+
} # End of PSData hashtable
61+
62+
} # End of PrivateData hashtable
63+
}

0 commit comments

Comments
 (0)