Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
driazati committed Dec 5, 2022
1 parent c31aba8 commit 40627e8
Show file tree
Hide file tree
Showing 14 changed files with 17 additions and 29 deletions.
3 changes: 1 addition & 2 deletions ci/jenkins/generated/arm_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/cortexm_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/cpu_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/docker_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/gpu_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/hexagon_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/i386_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/lint_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/minimal_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/riscv_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ci/jenkins/generated/wasm_jenkinsfile.groovy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion ci/jenkins/templates/utils/base.groovy.j2
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#!groovy
// -*- mode: groovy -*-

// Licensed to the Apache Software Foundation (ASF) under one
Expand Down
8 changes: 4 additions & 4 deletions ci/scripts/jenkins/open_docker_update_pr.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,16 +134,16 @@ def latest_tlcpackstaging_image(source: str) -> Optional[str]:
replacements = {}

for line in content:
m = re.match(r"^(ci_[a-zA-Z0-9]+) = \"(.*)\"", line.strip())
m = re.match(r'"tag": "(.*)",', line.strip())
if m is not None:
image_spec = m.groups()[0]
logging.info(f"Found match on line {line.strip()}")
groups = m.groups()
new_image = latest_tlcpackstaging_image(groups[1])
new_image = latest_tlcpackstaging_image(image_spec)
if new_image is None:
logging.info(f"No new image found")
else:
logging.info(f"Using new image {new_image}")
new_line = f"{groups[0]} = '{new_image}'\n"
new_line = f' "tag": "{new_image}",'
replacements[line] = new_line

# Re-generate the Jenkinsfiles
Expand Down
4 changes: 2 additions & 2 deletions tests/python/ci/test_ci.py
Original file line number Diff line number Diff line change
Expand Up @@ -1213,7 +1213,7 @@ def test_github_tag_teams(tmpdir_factory, source_type, data, check):
},
expected="Using tlcpackstaging tag on tlcpack",
expected_images=[
"ci_arm = 'tlcpack/ci-arm:456-456-abc'",
'"tag": "tlcpack/ci-arm:456-456-abc"',
],
),
tlcpack_update=dict(
Expand All @@ -1235,7 +1235,7 @@ def test_github_tag_teams(tmpdir_factory, source_type, data, check):
},
expected="Found newer image, using: tlcpack",
expected_images=[
"ci_arm = 'tlcpack/ci-arm:234-234-abc'",
'"tag": "tlcpack/ci-arm:234-234-abc",',
],
),
)
Expand Down

0 comments on commit 40627e8

Please sign in to comment.