Skip to content

Commit

Permalink
use proper demand when running TSA upload. (#205)
Browse files Browse the repository at this point in the history
* use proper demand when running TSA upload.

* Change test for export-crescendocommand.

The fields in the configuration can switch position because they are generated from a hashtable.
  • Loading branch information
JamesWTruher authored Jul 23, 2023
1 parent 54890e0 commit eee4584
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 2 additions & 0 deletions .ci/releaseBuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ stages:
- job: Compliance_Job
pool:
name: PowerShell1ES # Package ES CodeHub Lab E
demands:
- ImageOverride -equals PSMMS2019-Secure
steps:
- checkout: self
- checkout: ComplianceRepo
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -231,9 +231,11 @@ Describe "The class tests" {
It "Exports a configuration properly" {
$ci = New-CrescendoCommand -Verb Get -Noun Thing -OriginalName doesnotexist
Export-CrescendoCommand -command $ci -TargetDirectory ${TESTDRIVE}
$expected = (Get-Content "${PSScriptRoot}/assets/ExportCrescendoCommand1.json") -join [System.Environment]::NewLine
$observed = (Get-Content "${TESTDRIVE}/Get-Thing.crescendo.json") -join [System.Environment]::NewLine
$observed | Should -Be $expected
$expectedObject = Get-Content "${PSScriptRoot}/assets/ExportCrescendoCommand1.json" | ConvertFrom-Json
$observedObject = Get-Content "${TESTDRIVE}/Get-Thing.crescendo.json" | ConvertFrom-Json
$expectedObject.'$schema' | Should -Be $observedObject.'$schema'
$expectedObject.Commands[0].Verb | Should -Be $observedObject.Commands[0].Verb
$expectedObject.Commands[0].Noun | Should -Be $observedObject.Commands[0].Noun
}
}

Expand Down

0 comments on commit eee4584

Please sign in to comment.