tools: move make-bots, git-utils.sh to test/common
This will allow our subprojects to benefit from the "full strength" implementation of 'get me bots/' with symlink and caching support.
This commit is contained in:
parent
235a6124f0
commit
89db1c68a9
|
@ -18,7 +18,7 @@ jobs:
|
|||
|
||||
- name: Run npm-update bot
|
||||
run: |
|
||||
tools/make-bots
|
||||
test/common/make-bots
|
||||
git config --global user.name "GitHub Workflow"
|
||||
git config --global user.email "cockpituous@cockpit-project.org"
|
||||
mkdir -p ~/.config/cockpit-dev
|
||||
|
|
|
@ -18,7 +18,7 @@ jobs:
|
|||
|
||||
- name: Run npm-update bot
|
||||
run: |
|
||||
tools/make-bots
|
||||
test/common/make-bots
|
||||
git config --global user.name "GitHub Workflow"
|
||||
git config --global user.email "cockpituous@cockpit-project.org"
|
||||
mkdir -p ~/.config/cockpit-dev
|
||||
|
|
|
@ -18,5 +18,4 @@ jobs:
|
|||
|
||||
- name: Run urls-check action
|
||||
run: |
|
||||
tools/make-bots
|
||||
tools/urls-check
|
||||
|
|
|
@ -122,7 +122,7 @@ recheck-memory:
|
|||
# must be from main, as only that has current and existing images; but testvm.py API is stable
|
||||
# support CI testing against a bots change
|
||||
bots:
|
||||
tools/make-bots
|
||||
test/common/make-bots
|
||||
|
||||
.PHONY: rsync
|
||||
RSYNC_HOST ?= c
|
||||
|
|
|
@ -9,8 +9,8 @@ SUBDIR='bots'
|
|||
V="${V-0}" # default to friendly messages
|
||||
|
||||
set -eu
|
||||
cd "${0%/*}/.."
|
||||
. tools/git-utils.sh
|
||||
cd "${0%/*}/../.."
|
||||
. test/common/git-utils.sh
|
||||
|
||||
if [ ! -e bots ]; then
|
||||
[ -n "${quiet}" ] || set -x
|
|
@ -14,5 +14,5 @@ sys.path.append(f'{BOTS_DIR}/machine')
|
|||
|
||||
def ensure_bots():
|
||||
if not os.path.isdir(BOTS_DIR):
|
||||
subprocess.check_call([f'{BASE_DIR}/tools/make-bots'])
|
||||
subprocess.check_call([f'{BASE_DIR}/test/common/make-bots'])
|
||||
importlib.invalidate_caches()
|
||||
|
|
2
test/run
2
test/run
|
@ -5,7 +5,7 @@
|
|||
|
||||
set -eu
|
||||
|
||||
tools/make-bots
|
||||
test/common/make-bots
|
||||
test/common/pixel-tests pull
|
||||
|
||||
TEST_SCENARIO="${TEST_SCENARIO:-verify}"
|
||||
|
|
|
@ -7,7 +7,7 @@ V="${V-0}" # default to friendly messages
|
|||
|
||||
set -eu
|
||||
cd "${0%/*}/.."
|
||||
. tools/git-utils.sh
|
||||
. test/common/git-utils.sh
|
||||
|
||||
cmd_remove() {
|
||||
# if we did this for ourselves the rm is enough, but it might be the case
|
||||
|
@ -57,7 +57,7 @@ EOF
|
|||
}
|
||||
|
||||
cmd_install() {
|
||||
test -e bots || tools/make-bots
|
||||
test -e bots || test/common/make-bots
|
||||
|
||||
# We first read the result directly into the cache, then we unpack it.
|
||||
tree="$(bots/npm download < package.json | tar_to_cache)"
|
||||
|
@ -82,7 +82,7 @@ cmd_push() {
|
|||
}
|
||||
|
||||
cmd_verify() {
|
||||
test -e bots || tools/make-bots
|
||||
test -e bots || test/common/make-bots
|
||||
|
||||
# Verifies that the package.json and node_modules of the given commit match.
|
||||
commit="$(git rev-parse "$1:node_modules")"
|
||||
|
|
Loading…
Reference in New Issue