-
Notifications
You must be signed in to change notification settings - Fork 88
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #214 from PlagueHO/Issue-213
Prevent ResourceHelper and Common cmdlets from being exported - Fixes #213
- Loading branch information
Showing
20 changed files
with
223 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xDNSServerAddress/MSFT_xDNSServerAddress.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
...les/xNetworking/DSCResources/MSFT_xDefaultGatewayAddress/MSFT_xDefaultGatewayAddress.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xDhcpClient/MSFT_xDhcpClient.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
...s/xNetworking/DSCResources/MSFT_xDnsClientGlobalSetting/MSFT_xDnsClientGlobalSetting.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xDnsConnectionSuffix/MSFT_xDnsConnectionSuffix.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xFirewall/MSFT_xFirewall.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xHostsFile/MSFT_xHostsFile.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xIPAddress/MSFT_xIPAddress.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xNetAdapterBinding/MSFT_xNetAdapterBinding.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xNetAdapterLso/MSFT_xNetAdapterLso.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xNetAdapterName/MSFT_xNetAdapterName.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xNetAdapterRDMA/MSFT_xNetAdapterRDMA.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xNetBIOS/MSFT_xNetBIOS.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xNetConnectionProfile/MSFT_xNetConnectionProfile.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xNetworkTeam/MSFT_xNetworkTeam.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xNetworkTeamInterface/MSFT_xNetworkTeamInterface.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 10 additions & 3 deletions
13
Modules/xNetworking/DSCResources/MSFT_xRoute/MSFT_xRoute.psm1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
$script:DSCModuleName = 'xNetworking' | ||
<# | ||
These integration tests ensure that exported cmdlets names do not conflict | ||
with any other names that are exposed by other common resource kit modules. | ||
#> | ||
$script:ModulesToTest = @( 'xStorage','xComputerManagement','xDFS' ) | ||
|
||
#region HEADER | ||
# Integration Test Template Version: 1.1.0 | ||
[string] $script:moduleRoot = Join-Path -Path $(Split-Path -Parent (Split-Path -Parent (Split-Path -Parent $Script:MyInvocation.MyCommand.Path))) -ChildPath 'Modules\xNetworking' | ||
|
||
if ( (-not (Test-Path -Path (Join-Path -Path $script:moduleRoot -ChildPath 'DSCResource.Tests'))) -or ` | ||
(-not (Test-Path -Path (Join-Path -Path $script:moduleRoot -ChildPath 'DSCResource.Tests\TestHelper.psm1'))) ) | ||
{ | ||
& git @('clone','https://github.com/PowerShell/DscResource.Tests.git',(Join-Path -Path $script:moduleRoot -ChildPath '\DSCResource.Tests\')) | ||
} | ||
|
||
Import-Module (Join-Path -Path $script:moduleRoot -ChildPath 'DSCResource.Tests\TestHelper.psm1') -Force | ||
Import-Module (Join-Path -Path $script:moduleRoot -ChildPath "$($script:DSCModuleName).psd1") -Force | ||
$TestEnvironment = Initialize-TestEnvironment ` | ||
-DSCModuleName $script:DSCModuleName ` | ||
-DSCResourceName 'All' ` | ||
-TestType Integration | ||
|
||
#endregion | ||
|
||
# Using try/finally to always cleanup even if something awful happens. | ||
try | ||
{ | ||
Describe "$($script:DSCModuleName)_CommonModuleConflict" { | ||
|
||
foreach ($moduleToTest in $script:ModulesToTest) | ||
{ | ||
It "Should be able to install DSC Resource module '$moduleToTest'" { | ||
{ | ||
Install-Module -Name $moduleToTest -ErrorAction Stop | ||
} | Should Not Throw | ||
} | ||
} | ||
} | ||
} | ||
finally | ||
{ | ||
#region FOOTER | ||
Restore-TestEnvironment -TestEnvironment $TestEnvironment | ||
#endregion | ||
} |