From 63404d3d0dc29d5a4d7793dbfec2c56025643dfc Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Fri, 19 Jan 2018 10:57:23 -0600 Subject: [PATCH] Rename fetch-translations-stestr-output The role name is misleading. It's not fetching stestr output, it's fetching subunit output. Add a note to the README explaining what it does and that it's not using fetch-subunit-output on purpose. Use "{{ zuul.project.src_dir }}" instead of "src/{{ zuul.project.canonical_name }}". Change-Id: I1b5ab65f9697ec184969ca7899fb40294cdb853c --- .../translation/propose-translation-update.yaml | 4 ++-- .../translation/upstream-translation-update.yaml | 4 ++-- roles/fetch-translations-stestr-output/README.rst | 12 ------------ .../defaults/main.yaml | 2 -- roles/fetch-translations-subunit-output/README.rst | 14 ++++++++++++++ .../defaults/main.yaml | 2 ++ .../tasks/main.yaml | 0 7 files changed, 20 insertions(+), 18 deletions(-) delete mode 100644 roles/fetch-translations-stestr-output/README.rst delete mode 100644 roles/fetch-translations-stestr-output/defaults/main.yaml create mode 100644 roles/fetch-translations-subunit-output/README.rst create mode 100644 roles/fetch-translations-subunit-output/defaults/main.yaml rename roles/{fetch-translations-stestr-output => fetch-translations-subunit-output}/tasks/main.yaml (100%) diff --git a/playbooks/translation/propose-translation-update.yaml b/playbooks/translation/propose-translation-update.yaml index c870917826..ea23446103 100644 --- a/playbooks/translation/propose-translation-update.yaml +++ b/playbooks/translation/propose-translation-update.yaml @@ -8,8 +8,8 @@ - name: Run propose_translation_update.sh script command: "{{ ansible_user_dir }}/scripts/propose_translation_update.sh {{ zuul.project.short_name }} {{ zuul.branch }} {{ zuul.job }}" args: - chdir: "src/{{ zuul.project.canonical_name }}" + chdir: "{{ zuul.project.src_dir }}" - hosts: all roles: - - fetch-translations-stestr-output + - fetch-translations-subunit-output diff --git a/playbooks/translation/upstream-translation-update.yaml b/playbooks/translation/upstream-translation-update.yaml index cbe253938d..4dd438f1db 100644 --- a/playbooks/translation/upstream-translation-update.yaml +++ b/playbooks/translation/upstream-translation-update.yaml @@ -8,9 +8,9 @@ - name: Run upstream_translation_update.sh script command: "{{ ansible_user_dir }}/scripts/upstream_translation_update.sh {{ zuul.project.short_name }} {{ zuul.job }} {{zuul.branch}}" args: - chdir: "src/{{ zuul.project.canonical_name }}" + chdir: "{{ zuul.project.src_dir }}" - hosts: all roles: - fetch-translation-output - - fetch-translations-stestr-output + - fetch-translations-subunit-output diff --git a/roles/fetch-translations-stestr-output/README.rst b/roles/fetch-translations-stestr-output/README.rst deleted file mode 100644 index 9ce333bd7d..0000000000 --- a/roles/fetch-translations-stestr-output/README.rst +++ /dev/null @@ -1,12 +0,0 @@ -Collect stestr output from translation jobs - -This role collects only the testrepository.subunit file which has to -be compressed already. - -**Role Variables** - -.. zuul:rolevar:: zuul_work_dir - :default: {{ zuul.project.src_dir }} - - Directory where ``testrepository.subunit.gz`` file is. - diff --git a/roles/fetch-translations-stestr-output/defaults/main.yaml b/roles/fetch-translations-stestr-output/defaults/main.yaml deleted file mode 100644 index a0afa22c5c..0000000000 --- a/roles/fetch-translations-stestr-output/defaults/main.yaml +++ /dev/null @@ -1,2 +0,0 @@ ---- -zuul_work_dir: "src/{{ zuul.project.canonical_name }}" diff --git a/roles/fetch-translations-subunit-output/README.rst b/roles/fetch-translations-subunit-output/README.rst new file mode 100644 index 0000000000..ca24d22cb5 --- /dev/null +++ b/roles/fetch-translations-subunit-output/README.rst @@ -0,0 +1,14 @@ +Collect subunit output from translation jobs + +This role collects only the testrepository.subunit file which has +already been compressed. The common_translation_update.sh script +uses generate-subunit to create a subunit file containing success or +failure, thus :zuul:role:`fetch-subunit-output` is not appropriate. + +**Role Variables** + +.. zuul:rolevar:: zuul_work_dir + :default: {{ zuul.project.src_dir }} + + Directory where ``testrepository.subunit.gz`` file is. + diff --git a/roles/fetch-translations-subunit-output/defaults/main.yaml b/roles/fetch-translations-subunit-output/defaults/main.yaml new file mode 100644 index 0000000000..2cdab6ceb7 --- /dev/null +++ b/roles/fetch-translations-subunit-output/defaults/main.yaml @@ -0,0 +1,2 @@ +--- +zuul_work_dir: "{{ zuul.project.src_dir }}" diff --git a/roles/fetch-translations-stestr-output/tasks/main.yaml b/roles/fetch-translations-subunit-output/tasks/main.yaml similarity index 100% rename from roles/fetch-translations-stestr-output/tasks/main.yaml rename to roles/fetch-translations-subunit-output/tasks/main.yaml