pipeline-electron-build-and-test-and-nan.yml 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. name: Electron Build & Test (+ Node + NaN) Pipeline
  2. on:
  3. workflow_call:
  4. inputs:
  5. target-platform:
  6. type: string
  7. description: 'Platform to run on, can be macos, win or linux.'
  8. required: true
  9. target-arch:
  10. type: string
  11. description: 'Arch to build for, can be x64, arm64 or arm'
  12. required: true
  13. build-runs-on:
  14. type: string
  15. description: 'What host to run the build'
  16. required: true
  17. test-runs-on:
  18. type: string
  19. description: 'What host to run the tests on'
  20. required: true
  21. build-container:
  22. type: string
  23. description: 'JSON container information for aks runs-on'
  24. required: false
  25. default: '{"image":null}'
  26. test-container:
  27. type: string
  28. description: 'JSON container information for testing'
  29. required: false
  30. default: '{"image":null}'
  31. is-release:
  32. description: 'Whether this build job is a release job'
  33. required: true
  34. type: boolean
  35. default: false
  36. gn-build-type:
  37. description: 'The gn build type - testing or release'
  38. required: true
  39. type: string
  40. default: testing
  41. generate-symbols:
  42. description: 'Whether or not to generate symbols'
  43. required: true
  44. type: boolean
  45. default: false
  46. upload-to-storage:
  47. description: 'Whether or not to upload build artifacts to external storage'
  48. required: true
  49. type: string
  50. default: '0'
  51. is-asan:
  52. description: 'Building the Address Sanitizer (ASan) Linux build'
  53. required: false
  54. type: boolean
  55. default: false
  56. concurrency:
  57. group: electron-build-and-test-and-nan-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
  58. cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
  59. jobs:
  60. build:
  61. uses: ./.github/workflows/pipeline-segment-electron-build.yml
  62. with:
  63. build-runs-on: ${{ inputs.build-runs-on }}
  64. build-container: ${{ inputs.build-container }}
  65. target-platform: ${{ inputs.target-platform }}
  66. target-arch: ${{ inputs.target-arch }}
  67. is-release: ${{ inputs.is-release }}
  68. gn-build-type: ${{ inputs.gn-build-type }}
  69. generate-symbols: ${{ inputs.generate-symbols }}
  70. upload-to-storage: ${{ inputs.upload-to-storage }}
  71. secrets: inherit
  72. test:
  73. uses: ./.github/workflows/pipeline-segment-electron-test.yml
  74. needs: build
  75. with:
  76. target-arch: ${{ inputs.target-arch }}
  77. target-platform: ${{ inputs.target-platform }}
  78. test-runs-on: ${{ inputs.test-runs-on }}
  79. test-container: ${{ inputs.test-container }}
  80. secrets: inherit
  81. nn-test:
  82. uses: ./.github/workflows/pipeline-segment-node-nan-test.yml
  83. needs: build
  84. with:
  85. target-arch: ${{ inputs.target-arch }}
  86. target-platform: ${{ inputs.target-platform }}
  87. test-runs-on: ${{ inputs.test-runs-on }}
  88. test-container: ${{ inputs.test-container }}
  89. gn-build-type: ${{ inputs.gn-build-type }}
  90. secrets: inherit