mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 13:52:54 +00:00
Pass base branch to module validator on delegate.
This commit is contained in:
@@ -15,6 +15,7 @@ from lib.executor import (
|
||||
SubprocessError,
|
||||
ShellConfig,
|
||||
TestConfig,
|
||||
SanityConfig,
|
||||
create_shell_command,
|
||||
)
|
||||
|
||||
@@ -354,6 +355,9 @@ def generate_command(args, path, options, exclude, require):
|
||||
|
||||
if isinstance(args, ShellConfig):
|
||||
cmd = create_shell_command(cmd)
|
||||
elif isinstance(args, SanityConfig):
|
||||
if args.base_branch:
|
||||
cmd += ['--base-branch', args.base_branch]
|
||||
|
||||
return cmd
|
||||
|
||||
@@ -382,6 +386,10 @@ def filter_options(args, argv, options, exclude, require):
|
||||
'--changed-from': 1,
|
||||
'--changed-path': 1,
|
||||
})
|
||||
elif isinstance(args, SanityConfig):
|
||||
options.update({
|
||||
'--base-branch': 1,
|
||||
})
|
||||
|
||||
remaining = 0
|
||||
|
||||
|
||||
Reference in New Issue
Block a user