Skip to content
This repository has been archived by the owner on Oct 21, 2023. It is now read-only.

Commit

Permalink
Merge pull request #39 from scrthq/feature/build_and_test_updates
Browse files Browse the repository at this point in the history
merging build and test updates to master
  • Loading branch information
scrthq authored Oct 25, 2018
2 parents cb58f09 + b7b1858 commit 65603ef
Show file tree
Hide file tree
Showing 320 changed files with 391 additions and 1,379 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ launch.json
**insync**
vaporshell-snippets**
TestResults**.xml
out/*
BuildOutput/*
47 changes: 0 additions & 47 deletions .travis.yml

This file was deleted.

15 changes: 5 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,11 @@
<br />

<div align="center">
<!-- AppVeyor -->
<a href="https://ci.appveyor.com/project/scrthq/vaporshell/branch/master">
<img src="https://ci.appveyor.com/api/projects/status/8a4jsfv42tbmlym8/branch/master?svg=true"
alt="AppVeyor - Windows Build Status" title="AppVeyor - Windows Build Status" />
</a>&nbsp;&nbsp;&nbsp;
<!-- Travis CI -->
<a href="https://travis-ci.org/scrthq/VaporShell">
<img src="https://travis-ci.org/scrthq/VaporShell.svg?branch=master"
alt="Travis CI - Linux / macOS Build Status" title="Travis CI - Linux / macOS Build Status" />
</a>&nbsp;&nbsp;&nbsp;
<!-- Azure Pipelines -->
<a href="https://dev.azure.com/scrthq/SCRT%20HQ/_build/latest?definitionId=3">
<img src="https://dev.azure.com/scrthq/SCRT%20HQ/_apis/build/status/VaporShell-CI"
alt="Azure Pipelines" title="Azure Pipelines" />
</a>&nbsp;&nbsp;&nbsp;&nbsp;
<!-- Coveralls -->
<a href="https://coveralls.io/github/scrthq/Vaporshell?branch=master">
<img src="https://coveralls.io/repos/github/scrthq/Vaporshell/badge.svg?branch=master"
Expand Down
2 changes: 1 addition & 1 deletion Tests/Module Tests/VaporShell.Tests.ps1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$PSVersion = $PSVersionTable.PSVersion.Major
$projectRoot = Resolve-Path "$PSScriptRoot\..\.."
$ModulePath = Resolve-Path "$projectRoot\out\$($env:BHProjectName)"
$ModulePath = Resolve-Path "$projectRoot\BuildOutput\$($env:BHProjectName)"
$decompiledModulePath = Resolve-Path "$projectRoot\$($env:BHProjectName)"

# Verbose output for non-master builds on appveyor
Expand Down
16 changes: 15 additions & 1 deletion VaporShell/Public/Development Tools/Convert-SpecToFunction.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,14 @@ function $FunctionName {
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
"@

if ($Name -ne 'AWS::Events::EventBusPolicy') {
$scriptContents += @"
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.`n
"@
}
}
$scriptContents += @"
.FUNCTIONALITY
Expand Down Expand Up @@ -328,6 +331,9 @@ function $FunctionName {
`$PSCmdlet.ThrowTerminatingError((New-VSError -String "The UpdatePolicy parameter only accepts the following types: `$(`$allowedTypes -join ", "). The current types of the value are: `$(`$_.PSTypeNames -join ", ")."))
}
})]
"@
if ($Name -ne 'AWS::Events::EventBusPolicy') {
$scriptContents += @"
`$Metadata,
[parameter(Mandatory = `$false)]
[ValidateScript( {
Expand All @@ -342,6 +348,14 @@ function $FunctionName {
`$UpdatePolicy,
[parameter(Mandatory = `$false)]
`$Condition
"@
}
else {
$scriptContents += @"
`$Metadata
"@
}
$scriptContents += @"
)
Begin {
`$ResourceParams = @{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,13 @@ function Update-VSResourceFunctions {
$newType = $AfterTypeCount - $BeforeTypeCount
$newProp = $AfterPropCount - $BeforePropCount
Write-Verbose "`n`n$newType new Resource Type and $newProp Resource Property Type functions added to Vaporshell [$($newType + $newProp) total]`n"
}
Write-Host "Resource function update stats:"
[PSCustomObject][Ordered]@{
'Resource Type Functions [Before]' = $BeforeTypeCount
'Resource Type Functions [After]' = $AfterTypeCount
'Resource Type Functions [Diff]' = $newType
'Resource Prop Functions [Before]' = $BeforePropCount
'Resource Prop Functions [After]' = $AfterPropCount
'Resource Prop Functions [Diff]' = $newProp
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
function Add-VSEventsEventBusPolicyCondition {
<#
.SYNOPSIS
Adds an AWS::Events::EventBusPolicy.Condition resource property to the template
.DESCRIPTION
Adds an AWS::Events::EventBusPolicy.Condition resource property to the template
.LINK
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-events-eventbuspolicy-condition.html
.PARAMETER Type
Required: False
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-events-eventbuspolicy-condition.html#cfn-events-eventbuspolicy-condition-type
PrimitiveType: String
UpdateType: Mutable
.PARAMETER Value
Required: False
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-events-eventbuspolicy-condition.html#cfn-events-eventbuspolicy-condition-value
PrimitiveType: String
UpdateType: Mutable
.PARAMETER Key
Required: False
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-events-eventbuspolicy-condition.html#cfn-events-eventbuspolicy-condition-key
PrimitiveType: String
UpdateType: Mutable
.FUNCTIONALITY
Vaporshell
#>
[OutputType('Vaporshell.Resource.Events.EventBusPolicy.Condition')]
[cmdletbinding()]
Param
(
[parameter(Mandatory = $false)]
[ValidateScript( {
$allowedTypes = "System.String","Vaporshell.Function","Vaporshell.Condition"
if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") {
$true
}
else {
$PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ")."))
}
})]
$Type,
[parameter(Mandatory = $false)]
[ValidateScript( {
$allowedTypes = "System.String","Vaporshell.Function","Vaporshell.Condition"
if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") {
$true
}
else {
$PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ")."))
}
})]
$Value,
[parameter(Mandatory = $false)]
[ValidateScript( {
$allowedTypes = "System.String","Vaporshell.Function","Vaporshell.Condition"
if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") {
$true
}
else {
$PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ")."))
}
})]
$Key
)
Begin {
$obj = [PSCustomObject]@{}
$commonParams = @('Verbose','Debug','ErrorAction','WarningAction','InformationAction','ErrorVariable','WarningVariable','InformationVariable','OutVariable','OutBuffer','PipelineVariable')
}
Process {
foreach ($key in $PSBoundParameters.Keys | Where-Object {$commonParams -notcontains $_}) {
switch ($key) {
Default {
$obj | Add-Member -MemberType NoteProperty -Name $key -Value $PSBoundParameters.$key
}
}
}
}
End {
$obj | Add-ObjectDetail -TypeName 'Vaporshell.Resource.Events.EventBusPolicy.Condition'
Write-Verbose "Resulting JSON from $($MyInvocation.MyCommand): `n`n$($obj | ConvertTo-Json -Depth 5)`n"
}
}
22 changes: 11 additions & 11 deletions VaporShell/Public/Resource Property Types/Add-VSTag.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,18 @@
Adds an Tag resource property to the template
.LINK
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dms-endpoint-tag.html
.PARAMETER Key
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html#cfn-resource-tags-key
.PARAMETER Value
Required: False
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dms-endpoint-tag.html#cfn-dms-endpoint-tag-value
PrimitiveType: String
Required: True
UpdateType: Mutable
.PARAMETER Value
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html#cfn-resource-tags-value
.PARAMETER Key
Required: False
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dms-endpoint-tag.html#cfn-dms-endpoint-tag-key
PrimitiveType: String
Required: True
UpdateType: Mutable
.FUNCTIONALITY
Expand All @@ -28,7 +28,7 @@
[cmdletbinding()]
Param
(
[parameter(Mandatory = $true)]
[parameter(Mandatory = $false)]
[ValidateScript( {
$allowedTypes = "System.String","Vaporshell.Function","Vaporshell.Condition"
if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") {
Expand All @@ -38,8 +38,8 @@
$PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ")."))
}
})]
$Key,
[parameter(Mandatory = $true)]
$Value,
[parameter(Mandatory = $false)]
[ValidateScript( {
$allowedTypes = "System.String","Vaporshell.Function","Vaporshell.Condition"
if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") {
Expand All @@ -49,7 +49,7 @@
$PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ")."))
}
})]
$Value
$Key
)
Begin {
$obj = [PSCustomObject]@{}
Expand Down
6 changes: 2 additions & 4 deletions VaporShell/Public/Resource Types/New-VSAmazonMQBroker.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
Required: True
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-amazonmq-broker.html#cfn-amazonmq-broker-engineversion
PrimitiveType: String
UpdateType: Immutable
UpdateType: Mutable
.PARAMETER Configuration
Type: ConfigurationId
Expand All @@ -47,7 +47,7 @@
Required: True
Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-amazonmq-broker.html#cfn-amazonmq-broker-autominorversionupgrade
PrimitiveType: Boolean
UpdateType: Immutable
UpdateType: Mutable
.PARAMETER Users
Type: List
Expand Down Expand Up @@ -117,8 +117,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
2 changes: 0 additions & 2 deletions VaporShell/Public/Resource Types/New-VSApiGatewayAccount.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
2 changes: 0 additions & 2 deletions VaporShell/Public/Resource Types/New-VSApiGatewayApiKey.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@
Use the UpdatePolicy attribute to specify how AWS CloudFormation handles updates to the AWS::AutoScaling::AutoScalingGroup resource. AWS CloudFormation invokes one of three update policies depending on the type of change you make or whether a scheduled action is associated with the Auto Scaling group.
You must use the "Add-UpdatePolicy" function here.
.PARAMETER Condition
Logical ID of the condition that this resource needs to be true in order for this resource to be provisioned.
Expand Down
Loading

0 comments on commit 65603ef

Please sign in to comment.