8PYTHON_VERSION_COMPATIBILITY =
"PY3"
12 'recipe_engine/context',
14 'recipe_engine/properties',
21 with api.context(cwd=repo_root, env=env):
23 api.step(
'git init', cmd=[
'git',
'init'])
24 api.step(
'git add .', cmd=[
'git',
'add',
'.'])
25 api.step(
'git commit', cmd=[
'git',
'commit',
'-a',
'-m',
'initial commit'])
32 repo_name = api.properties[
'repository'].split(
'/')[-1]
33 if repo_name.endswith(
'.git'):
34 repo_name = repo_name[:-
len(
'.git')]
35 repo_root = api.path.start_dir.join(repo_name)
36 infra_tests = repo_root.join(
'infra',
'bots',
'infra_tests.py')
40 env.update(api.infra.go_env)
41 for k, v
in api.vars.default_env.items():
46 env[k] = env[k] % {k: v}
51 if repo_name !=
'skia':
52 git_init(api, api.path.start_dir.join(
'skia'), env)
54 with api.context(cwd=repo_root, env=env):
60 api.step(
'infra_tests', cmd=[
'python3',
'-u', infra_tests])
62 except api.step.StepFailure
as e:
69 api.test(
'infra_tests') +
70 api.properties(buildername=
'Housekeeper-PerCommit-InfraTests_Linux',
71 repository=
'https://skia.googlesource.com/skia.git',
72 path_config=
'kitchen',
73 swarm_out_dir=
'[SWARM_OUT_DIR]')
76 api.test(
'infra_tests_lottie_ci') +
77 api.properties(buildername=
'Housekeeper-PerCommit-InfraTests_Linux',
78 repository=
'https://skia.googlesource.com/lottie-ci.git',
79 path_config=
'kitchen',
80 swarm_out_dir=
'[SWARM_OUT_DIR]')
def git_init(api, repo_root, env)