Skip to content

Commit

Permalink
Merge branch 'pr/MichelZ/257'
Browse files Browse the repository at this point in the history
  • Loading branch information
DarqueWarrior committed Feb 24, 2020
2 parents a63e444 + cfc10f3 commit c517f37
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 20 deletions.
21 changes: 3 additions & 18 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,10 @@
# Changelog

## 6.4.3

Merged [Pull Request](https://github.com/DarqueWarrior/vsteam/pull/224) from [Steven Cady](https://github.com/cadacious) which included the following:

Added Remove-VSTeamAccessControlEntry to delete users/groups from Access Control Lists within security namespaces. Supports removing single or multiple entries. Only supports removing vsts origin users/groups.

## 6.4.2

Merged [Pull Request](https://github.com/DarqueWarrior/vsteam/pull/226) from [Asif Mithawala](https://github.com/asifma) which included the following:

Added property checks in VSTeamJobRequest

Merged [Pull Request](https://github.com/DarqueWarrior/vsteam/pull/227) from [Sebastian Schütze](https://github.com/SebastianSchuetze) which included the following:
## 6.4.5

Added Remove-VSTeamWorkItem to delete work items
Merged [Pull Request](https://github.com/DarqueWarrior/vsteam/pull/257) from [Michel Zehnder](https://github.com/MichelZ) which included the following:

- Added a parameter to filter unit tests
- Added documentation on parameters of Build-Module.ps1 in code and for README.MD
- Removed references to update the .PSD1 file in the PR template as well as in the contribution doc, since it does not seem to be needed anymore, because it is generated automatically.
- Added coverage.xml to the .gitignore file
Fix bug in Get-VSTeamBuildArtifact with additional "properties" property

## 6.4.4

Expand Down
2 changes: 1 addition & 1 deletion Source/Private/applyTypes.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ function _applyTypesToBuild {
function _applyArtifactTypes {
$item.PSObject.TypeNames.Insert(0, "Team.Build.Artifact")

if ($item.PSObject.Properties.Match('resource').count -gt 0 -and $null -ne $item.resource) {
if ($item.PSObject.Properties.Match('resource').count -gt 0 -and $null -ne $item.resource -and $item.resource.PSObject.Properties.Match('propeties').count -gt 0) {
$item.resource.PSObject.TypeNames.Insert(0, 'Team.Build.Artifact.Resource')
$item.resource.properties.PSObject.TypeNames.Insert(0, 'Team.Build.Artifact.Resource.Properties')
}
Expand Down
2 changes: 1 addition & 1 deletion Source/VSTeam.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
RootModule = 'VSTeam.psm1'

# Version number of this module.
ModuleVersion = '6.4.4'
ModuleVersion = '6.4.5'

# Supported PSEditions
# CompatiblePSEditions = @()
Expand Down
22 changes: 22 additions & 0 deletions unit/test/builds.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,28 @@ InModuleScope VSTeam {
}
}
}

Context "Get-VSTeamBuildArtifact result without properties" {
Mock Invoke-RestMethod { return [PSCustomObject]@{
value = [PSCustomObject]@{
id = 150
name = "Drop"
resource = [PSCustomObject]@{
type = "filepath"
data = "C:\Test"
}
}
}
}

Get-VSTeamBuildArtifact -projectName project -id 2

It 'should return the build artifact data' {
Assert-MockCalled Invoke-RestMethod -Exactly -Scope Context -Times 1 -ParameterFilter {
$Uri -eq "https://dev.azure.com/test/project/_apis/build/builds/2/artifacts?api-version=$([VSTeamVersions]::Build)"
}
}
}
}

Describe 'Builds TFS' {
Expand Down

0 comments on commit c517f37

Please sign in to comment.