-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
23,035 additions
and
346 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
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,96 @@ | ||
# Builds react-lib, js-lib and links the packages. | ||
resources: | ||
- repo: self | ||
clean: true | ||
|
||
# Trigger whenever a PR is submitted | ||
pr: | ||
branches: | ||
include: | ||
- main | ||
paths: | ||
include: | ||
- visualization | ||
|
||
variables: | ||
rootDirectory: visualization | ||
project: $(rootDirectory)/react-lib | ||
jslib: $(rootDirectory)/js-lib | ||
reactnodemodules: node_modules/react | ||
projectname: quantum-visualization | ||
outputDirectory: $(Agent.BuildDirectory)/output | ||
tests: $(project)/TestResults | ||
|
||
stages: | ||
- stage: Build_Visualization_Library | ||
pool: | ||
vmImage: "windows-latest" | ||
jobs: | ||
- job: Build_Test_Link_Publish | ||
steps: | ||
- task: UseDotNet@2 | ||
inputs: | ||
version: "3.1.x" | ||
|
||
- task: NodeTool@0 | ||
inputs: | ||
versionSpec: "16.x" | ||
|
||
- task: Npm@1 | ||
displayName: npm run lint (react-lib) | ||
inputs: | ||
workingDir: "$(project)" | ||
command: "custom" | ||
customCommand: "run lint" | ||
|
||
- task: Bash@3 | ||
displayName: "Build js-lib and dependencies" | ||
inputs: | ||
targetType: "filePath" | ||
filePath: "$(rootDirectory)/build/build-jslib.sh" | ||
failOnStderr: true | ||
workingDirectory: "$(rootDirectory)/build/" | ||
|
||
# - task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1 | ||
# displayName: 'Signing' | ||
# inputs: | ||
# ConnectedServiceName: CodeSign | ||
# FolderPath: "$(jslib)/dist/" | ||
# Pattern: "*.js" | ||
# CertificateId: 100040160 | ||
# OpusName: "Microsoft Quantum Development Kit" | ||
# OpusInfo: "https://www.microsoft.com/quantum" | ||
# SessionTimeout: 120 | ||
|
||
- task: CopyFiles@2 | ||
inputs: | ||
SourceFolder: "$(jslib)/dist/" | ||
Contents: "**" | ||
TargetFolder: "$(outputDirectory)" | ||
displayName: "Copy build artifacts to output directory" | ||
|
||
- task: Npm@1 | ||
displayName: npm run tests (react-lib) | ||
inputs: | ||
workingDir: "$(project)" | ||
command: "custom" | ||
customCommand: "run testsonly" | ||
|
||
- task: PublishTestResults@2 | ||
displayName: "Publish Test Results (react-lib)" | ||
condition: succeededOrFailed() | ||
inputs: | ||
testResultsFiles: "$(tests)/test-results.xml" | ||
|
||
- task: PublishCodeCoverageResults@1 | ||
displayName: "Publish Code Coverage Results (react-lib)" | ||
condition: succeededOrFailed() | ||
inputs: | ||
codeCoverageTool: "cobertura" | ||
summaryFileLocation: "$(project)/coverage/cobertura-coverage.xml" | ||
|
||
- task: PublishPipelineArtifact@1 | ||
inputs: | ||
targetPath: $(outputDirectory)" | ||
artifactType: "pipeline" | ||
artifactName: "microsoft-visualization" |
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,93 @@ | ||
# Builds react-lib, js-lib and links the packages. | ||
resources: | ||
- repo: self | ||
clean: true | ||
|
||
# Trigger whenever a commit occurs in these branches | ||
trigger: | ||
branches: | ||
include: | ||
- main | ||
|
||
variables: | ||
rootDirectory: visualization | ||
project: $(rootDirectory)/react-lib | ||
jslib: $(rootDirectory)/js-lib | ||
reactnodemodules: node_modules/react | ||
projectname: quantum-visualization | ||
outputDirectory: $(Agent.BuildDirectory)/output | ||
tests: $(project)/TestResults | ||
|
||
stages: | ||
- stage: Build_Visualization_Library | ||
pool: | ||
vmImage: "windows-latest" | ||
jobs: | ||
- job: Build_Test_Link_Publish | ||
steps: | ||
- task: UseDotNet@2 | ||
inputs: | ||
version: "3.1.x" | ||
|
||
- task: NodeTool@0 | ||
inputs: | ||
versionSpec: "16.x" | ||
|
||
- task: Npm@1 | ||
displayName: npm run lint (react-lib) | ||
inputs: | ||
workingDir: "$(project)" | ||
command: "custom" | ||
customCommand: "run lint" | ||
|
||
- task: Bash@3 | ||
displayName: "Build js-lib and dependencies" | ||
inputs: | ||
targetType: "filePath" | ||
filePath: "$(rootDirectory)/build/build-jslib.sh" | ||
failOnStderr: true | ||
workingDirectory: "$(rootDirectory)/build/" | ||
|
||
# - task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1 | ||
# displayName: 'Signing' | ||
# inputs: | ||
# ConnectedServiceName: CodeSign | ||
# FolderPath: "$(jslib)/dist/" | ||
# Pattern: "*.js" | ||
# CertificateId: 100040160 | ||
# OpusName: "Microsoft Quantum Development Kit" | ||
# OpusInfo: "https://www.microsoft.com/quantum" | ||
# SessionTimeout: 120 | ||
|
||
- task: CopyFiles@2 | ||
inputs: | ||
SourceFolder: "$(jslib)/dist/" | ||
Contents: "**" | ||
TargetFolder: "$(outputDirectory)" | ||
displayName: "Copy build artifacts to output directory" | ||
|
||
- task: Npm@1 | ||
displayName: npm run tests (react-lib) | ||
inputs: | ||
workingDir: "$(project)" | ||
command: "custom" | ||
customCommand: "run testsonly" | ||
|
||
- task: PublishTestResults@2 | ||
displayName: "Publish Test Results (react-lib)" | ||
condition: succeededOrFailed() | ||
inputs: | ||
testResultsFiles: "$(tests)/test-results.xml" | ||
|
||
- task: PublishCodeCoverageResults@1 | ||
displayName: "Publish Code Coverage Results (react-lib)" | ||
condition: succeededOrFailed() | ||
inputs: | ||
codeCoverageTool: "cobertura" | ||
summaryFileLocation: "$(project)/coverage/cobertura-coverage.xml" | ||
|
||
- task: PublishPipelineArtifact@1 | ||
inputs: | ||
targetPath: $(outputDirectory)" | ||
artifactType: "pipeline" | ||
artifactName: "microsoft-visualization" |
Oops, something went wrong.