These are scripts that must be present in the ci
directory of each repository that uses the common workflows.
Script: build-project.ps1
Builds the project. This is passed any build configuration parameters required from the options.json
, and should call language specific build scripts in common-ci
where possible.
Script: build-package.ps1
Build a package ready for testing and publishing.
Any requirements from build-package-requirements
will be downloaded to package-files
before this script is called.
This should output any package files to the package
directory.
Script: build-package-requirements.ps1
This should build any config specific requirements for the package. For example, native binaries that need to be built on different platforms before being combined in the final package.
This should output any files required for the package to the package-files
directory.
Script: fetch-assets.ps1
Fetches any assets needed for building or testing. This should reuse common asset steps. It is passed a keys
object as a parameter, which is a hashtable of any named keys passed as secrets to the the workflow.
Script: get-next-package-version.ps1
Gets the next version for the package. This must take a parameter of ParameterName
, which it then must set to a string containing the next version for the package.
This should make use of the common version which returns the versions from GitVersion as an object.
Script: install-package.ps1
Install a prebuilt package locally from the package
directory.
As an example, if a NuGet package is downloaded to the package
directory. This script would install it using NuGet.
Script: package-dependency-update.ps1
Updated any package dependencies to the latest patch version. This should reuse language specific scripts in common-ci
where possible.
Script: publish-package.ps1
Publish the local package (which was built with build-package.ps1
and installed locally with install-package.ps1
) to the appropriate package manager. This should use language specific scripts in common-ci
where possible.
Script: run-integration-tests.ps1
Run any integration tests for the project. For implementation guidelines, see Integration Tests. This should use language specific scripts in common-ci
where possible.
Results should be written to the [repo]/test-results/integration
directory. Supported formats can be found on the publish-unit-test-result action readme.
Script: run-performance-tests.ps1
Run any performance tests for the project. For implementation guidelines, see Integration Tests. This should use language specific scripts in common-ci
where possible.
Results should be written to the [repo]/test-results/performance
directory. Supported formats can be found on the publish-unit-test-result action readme.
Performance figures are different from test results. These should be written to the [repo]/test-results/performance-summary/
directory in a specific format. See the Performance Tests section for details.
Script: run-unit-tests.ps1
Run any unit tests for the project. This should use language specific scripts in common-ci
where possible.
Results should be written to the [repo]/test-results/unit
directory. Supported formats can be found on the publish-unit-test-result action readme.
Script: setup-environment.ps1
Setup any environment variables, or install any tools required for building and testing. This should use scripts from common-ci/environments
where possible. See Environments.
Script: options.json
This is an array of options which are passed to the scripts as parameters. For a more detailed description, see Options.