|
|
@@ -291,7 +291,6 @@ describe('Python release workflows', () => {
|
|
|
it('keeps complete wheel validation separate from protected public publication', () => {
|
|
|
const workflow = loadWorkflow('.github/workflows/python-release.yml')
|
|
|
const dispatch = workflowEvent(workflow, 'workflow_dispatch')
|
|
|
- const pullRequest = workflowEvent(workflow, 'pull_request')
|
|
|
const build = workflowJob(workflow, 'build')
|
|
|
const pythonCompat = workflowJob(workflow, 'python-compat')
|
|
|
const validate = workflowJob(workflow, 'validate')
|
|
|
@@ -307,9 +306,9 @@ describe('Python release workflows', () => {
|
|
|
}
|
|
|
|
|
|
expect(dispatch.inputs.publish).toMatchObject({ type: 'boolean', default: false })
|
|
|
- expect(pullRequest).toEqual({ types: ['labeled'] })
|
|
|
+ if (!isRecord(workflow.on)) throw new TypeError('python-release workflow must define on')
|
|
|
+ expect(Object.keys(workflow.on)).toEqual(['workflow_dispatch'])
|
|
|
expect(build).toMatchObject({
|
|
|
- if: "github.event_name == 'workflow_dispatch' || github.event.label.name == 'python-release-dry-run'",
|
|
|
uses: './.github/workflows/build-exe-for-python-sdk.yml',
|
|
|
with: {
|
|
|
targets: 'node24-linux-x64,node24-linux-arm64,node24-macos-arm64',
|