Skip to content

fix ci failures #2478

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .vsts-ci/azure-pipelines-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ variables:
- name: DOTNET_CLI_TELEMETRY_OPTOUT
value: 'true'

- name: BLAH
value: $(PLEASE_WORK)

trigger:
batch: true
branches:
Expand Down Expand Up @@ -43,6 +46,11 @@ jobs:
pool:
vmImage: 'macOS-10.14'
steps:
- pwsh: |
Get-ChildItem -Path env:
Write-Host '$(BLAH) this is something'
displayName: Capture environment
condition: succeededOrFailed()
- template: templates/ci-general.yml

- job: Linux
Expand Down
11 changes: 11 additions & 0 deletions .vsts-ci/templates/ci-general.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,32 @@ steps:
- pwsh: Write-Host "##vso[build.updatebuildnumber]$env:BUILD_SOURCEBRANCHNAME-$env:BUILD_SOURCEVERSION-$((get-date).ToString("yyyyMMddhhmmss"))"
displayName: Set Build Name for Non-PR
condition: ne(variables['Build.Reason'], 'PullRequest')

- pwsh: |
git clone https://github.com/PowerShell/PowerShellEditorServices.git ../PowerShellEditorServices
Install-Module InvokeBuild -Scope CurrentUser -Force
Install-Module PlatyPS -Scope CurrentUser -Force

# Build
- pwsh: |
Get-ChildItem -Path env:
Write-Host '$(PS_TEST_GITHUB_API_PAT) this is something'
displayName: Capture environment
condition: succeededOrFailed()

- pwsh: Invoke-Build

- task: PublishTestResults@2
inputs:
testRunner: JUnit
testResultsFiles: '**/test-results.xml'
condition: succeededOrFailed()

- task: PublishBuildArtifacts@1
inputs:
ArtifactName: vscode-powershell
PathtoPublish: '$(Build.ArtifactStagingDirectory)'

# Rich Navigation
- task: RichCodeNavIndexer@0
# Note, for now, this is Windows only.
Expand Down
2 changes: 1 addition & 1 deletion src/features/UpdatePowerShell.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export class GitHubReleaseInformation {

if (!response.ok) {
const json = await response.json();
throw json.message || json || "response was not ok.";
throw new Error(json.message || json || "response was not ok.");
}

// For preview, we grab all the releases and then grab the first prerelease.
Expand Down
2 changes: 1 addition & 1 deletion vscode-powershell.build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ task Test Build, {
return
}
Write-Host "`n### Running extension tests" -ForegroundColor Green
exec { & npm run test }
exec { npm run test }
}

task TestEditorServices {
Expand Down