From 595d19c321953847dfdb8e94c470702797d29d72 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 13:34:29 +0300 Subject: [PATCH 01/12] parallelize tests by tags --- .circleci/config.yml | 253 ++++++++++++++++++++++--------------------- .gitmodules | 2 +- priv/cabbage | 2 +- 3 files changed, 130 insertions(+), 127 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 91e384b8bb..61ea6c7792 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -97,7 +97,7 @@ commands: name: Standup Geth and Child Chain command: docker-compose up geth childchain postgres background: true - - run: + - run: name: Has Childchain started? command: | attempt_counter=0 @@ -600,6 +600,7 @@ jobs: test_docker_compose_release: machine: image: ubuntu-1604:201903-01 + parallelism: 4 steps: - checkout - run: @@ -638,7 +639,9 @@ jobs: mix format apps/child_chain_api/lib/child_chain_api/model/*.ex mix format apps/watcher_info_api/lib/watcher_info_api/model/*.ex mix format apps/watcher_security_critical_api/lib/watcher_security_critical_api/model/*.ex - MIX_ENV=test mix do compile --warnings-as-errors --ignore-module-conflict --force, test --exclude test + echo &("configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split) + "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split > /tmp/tests-to-run + MIX_ENV=test mix do compile --warnings-as-errors --ignore-module-conflict --force, test --exclude test --only $(cat /tmp/tests-to-run) - save_cache: key: v2-mix-specs-cache-{{ .Branch }}-{{ checksum "mix.lock" }} paths: @@ -756,7 +759,7 @@ jobs: make install make generate_api_code mix deps.get - mix test --only reorg --trace + mix test --only deposit --trace no_output_timeout: 30m test_barebone_release: @@ -818,7 +821,7 @@ jobs: ps axww | grep watcher ps axww | grep watcher_info ps axww | grep child_chain - - run: + - run: name: Has Watcher started? command: | attempt_counter=0 @@ -832,7 +835,7 @@ jobs: attempt_counter=$(($attempt_counter+1)) sleep 5 done - - run: + - run: name: Has Watcher Info started? command: | attempt_counter=0 @@ -845,8 +848,8 @@ jobs: printf '.' attempt_counter=$(($attempt_counter+1)) sleep 5 - done - + done + publish_watcher: machine: @@ -1001,123 +1004,123 @@ workflows: only: /.+/ tags: only: /.+/ - - test_barebone_release: - filters: *all_branches_and_tags - - notify_services: - requires: - - increase_chart_version_watcher_master - - increase_chart_version_watcher_info_master - filters: - branches: - only: - - master - - coveralls_report: - requires: - - watcher_coveralls_and_integration_tests - - watcher_info_coveralls_and_integration_tests - - common_coveralls_and_integration_tests - - test - - watcher_coveralls_and_integration_tests: - requires: [build] - filters: *all_branches_and_tags - - watcher_info_coveralls_and_integration_tests: - requires: [build] - filters: *all_branches_and_tags - - common_coveralls_and_integration_tests: - requires: [build] - filters: *all_branches_and_tags + # - test_barebone_release: + # filters: *all_branches_and_tags + # - notify_services: + # requires: + # - increase_chart_version_watcher_master + # - increase_chart_version_watcher_info_master + # filters: + # branches: + # only: + # - master + # - coveralls_report: + # requires: + # - watcher_coveralls_and_integration_tests + # - watcher_info_coveralls_and_integration_tests + # - common_coveralls_and_integration_tests + # - test + # - watcher_coveralls_and_integration_tests: + # requires: [build] + # filters: *all_branches_and_tags + # - watcher_info_coveralls_and_integration_tests: + # requires: [build] + # filters: *all_branches_and_tags + # - common_coveralls_and_integration_tests: + # requires: [build] + # filters: *all_branches_and_tags - test_docker_compose_release: filters: *all_branches_and_tags - - test_docker_compose_performance: - filters: *all_branches_and_tags - - test_docker_compose_reorg: - filters: *all_branches_and_tags - - audit_deps: - requires: [build] - filters: *all_branches_and_tags - - lint: - requires: [build] - filters: *all_branches_and_tags - - lint_version: - requires: [build] - filters: *all_branches_and_tags - - sobelow: - requires: [build] - filters: *all_branches_and_tags - - dialyzer: - requires: [build] - filters: *all_branches_and_tags - - test: - requires: [build] - filters: *all_branches_and_tags - - property_tests: - requires: [build] - filters: *all_branches_and_tags - - watcher_mix_based_childchain: - filters: *all_branches_and_tags - - publish_watcher: - requires: - [ - test_barebone_release, - test_docker_compose_release, - watcher_coveralls_and_integration_tests, - watcher_info_coveralls_and_integration_tests, - common_coveralls_and_integration_tests, - test, - property_tests, - dialyzer, - lint, - lint_version, - audit_deps - ] - filters: &master_and_version_branches_and_all_tags - branches: - only: - - master - # vMAJOR.MINOR (e.g. v0.1, v0.2, v1.0, v2.1, etc.) - - /^v[0-9]+\.[0-9]+/ - tags: - only: - - /.+/ - - publish_watcher_info: - requires: - [ - test_barebone_release, - test_docker_compose_release, - watcher_coveralls_and_integration_tests, - watcher_info_coveralls_and_integration_tests, - common_coveralls_and_integration_tests, - test, - property_tests, - dialyzer, - lint, - lint_version, - audit_deps - ] - filters: *master_and_version_branches_and_all_tags - # Increase chart version for master, this will end up trigger deployment on dev - - increase_chart_version_watcher_master: - requires: [publish_watcher, publish_watcher_info] - filters: - branches: - only: - - master - - increase_chart_version_watcher_info_master: - requires: [publish_watcher, publish_watcher_info] - filters: - branches: - only: - - master - # Increase chart version for new release - - increase_chart_version_watcher_release: - requires: [publish_watcher, publish_watcher_info] - filters: &only_release_tag - branches: - ignore: /.*/ - tags: - only: - # eg. v1.0.3-pre.0, v1.0.3, ... - - /^v[0-9]+\.[0-9]+\.[0-9]+.*/ - - increase_chart_version_watcher_info_release: - requires: [publish_watcher, publish_watcher_info] - filters: *only_release_tag \ No newline at end of file + # - test_docker_compose_performance: + # filters: *all_branches_and_tags + # - test_docker_compose_reorg: + # filters: *all_branches_and_tags + # - audit_deps: + # requires: [build] + # filters: *all_branches_and_tags + # - lint: + # requires: [build] + # filters: *all_branches_and_tags + # - lint_version: + # requires: [build] + # filters: *all_branches_and_tags + # - sobelow: + # requires: [build] + # filters: *all_branches_and_tags + # - dialyzer: + # requires: [build] + # filters: *all_branches_and_tags + # - test: + # requires: [build] + # filters: *all_branches_and_tags + # - property_tests: + # requires: [build] + # filters: *all_branches_and_tags + # - watcher_mix_based_childchain: + # filters: *all_branches_and_tags + # - publish_watcher: + # requires: + # [ + # test_barebone_release, + # test_docker_compose_release, + # watcher_coveralls_and_integration_tests, + # watcher_info_coveralls_and_integration_tests, + # common_coveralls_and_integration_tests, + # test, + # property_tests, + # dialyzer, + # lint, + # lint_version, + # audit_deps + # ] + # filters: &master_and_version_branches_and_all_tags + # branches: + # only: + # - master + # # vMAJOR.MINOR (e.g. v0.1, v0.2, v1.0, v2.1, etc.) + # - /^v[0-9]+\.[0-9]+/ + # tags: + # only: + # - /.+/ + # - publish_watcher_info: + # requires: + # [ + # test_barebone_release, + # test_docker_compose_release, + # watcher_coveralls_and_integration_tests, + # watcher_info_coveralls_and_integration_tests, + # common_coveralls_and_integration_tests, + # test, + # property_tests, + # dialyzer, + # lint, + # lint_version, + # audit_deps + # ] + # filters: *master_and_version_branches_and_all_tags + # # Increase chart version for master, this will end up trigger deployment on dev + # - increase_chart_version_watcher_master: + # requires: [publish_watcher, publish_watcher_info] + # filters: + # branches: + # only: + # - master + # - increase_chart_version_watcher_info_master: + # requires: [publish_watcher, publish_watcher_info] + # filters: + # branches: + # only: + # - master + # # Increase chart version for new release + # - increase_chart_version_watcher_release: + # requires: [publish_watcher, publish_watcher_info] + # filters: &only_release_tag + # branches: + # ignore: /.*/ + # tags: + # only: + # # eg. v1.0.3-pre.0, v1.0.3, ... + # - /^v[0-9]+\.[0-9]+\.[0-9]+.*/ + # - increase_chart_version_watcher_info_release: + # requires: [publish_watcher, publish_watcher_info] + # filters: *only_release_tag diff --git a/.gitmodules b/.gitmodules index ebb28fdad5..139cd6ae10 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,4 +1,4 @@ [submodule "priv/cabbage"] path = priv/cabbage url = https://github.com/omgnetwork/specs.git - branch = master + branch = ayrat555/parallelize-tests diff --git a/priv/cabbage b/priv/cabbage index 4fe4bc8f40..e11f8c26a0 160000 --- a/priv/cabbage +++ b/priv/cabbage @@ -1 +1 @@ -Subproject commit 4fe4bc8f40761981d837d54e430e7ae705b942c3 +Subproject commit e11f8c26a0017318301392c7d768cd5655bf49c0 From 9b80e5136d04b06bda663c8e99e364ad6536744b Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 13:46:22 +0300 Subject: [PATCH 02/12] move split to another step --- .circleci/config.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 61ea6c7792..bec4008842 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -629,7 +629,9 @@ jobs: make install make generate_api_code mix deps.get - mix test + echo &("configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split) + "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split > /tmp/tests-to-run + mix test --only $(cat /tmp/tests-to-run) - run: name: (Cabbage) Format generated code and check for warnings command: | @@ -639,9 +641,7 @@ jobs: mix format apps/child_chain_api/lib/child_chain_api/model/*.ex mix format apps/watcher_info_api/lib/watcher_info_api/model/*.ex mix format apps/watcher_security_critical_api/lib/watcher_security_critical_api/model/*.ex - echo &("configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split) - "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split > /tmp/tests-to-run - MIX_ENV=test mix do compile --warnings-as-errors --ignore-module-conflict --force, test --exclude test --only $(cat /tmp/tests-to-run) + MIX_ENV=test mix do compile --warnings-as-errors --ignore-module-conflict --force, test --exclude test - save_cache: key: v2-mix-specs-cache-{{ .Branch }}-{{ checksum "mix.lock" }} paths: From fce62a494ba3f14f76355d0c6b606349412d887f Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 14:01:42 +0300 Subject: [PATCH 03/12] fix interpolation symbol --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index bec4008842..c51dccbb0e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -629,7 +629,7 @@ jobs: make install make generate_api_code mix deps.get - echo &("configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split) + echo $("configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split) "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split > /tmp/tests-to-run mix test --only $(cat /tmp/tests-to-run) - run: From fdc7a2af344aa6d17be44b2c7ef142c151137ea1 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 14:14:39 +0300 Subject: [PATCH 04/12] fix split command --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c51dccbb0e..513635d04d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -629,8 +629,8 @@ jobs: make install make generate_api_code mix deps.get - echo $("configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split) - "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" | circleci tests split > /tmp/tests-to-run + echo $(circleci tests split "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status") + circleci tests split "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" > /tmp/tests-to-run mix test --only $(cat /tmp/tests-to-run) - run: name: (Cabbage) Format generated code and check for warnings From e1bab081adaa575cbab008480e3443317a820469 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 14:50:23 +0300 Subject: [PATCH 05/12] write tags to file --- .circleci/config.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 513635d04d..e7a2d0d3d1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -629,8 +629,9 @@ jobs: make install make generate_api_code mix deps.get - echo $(circleci tests split "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status") - circleci tests split "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" > /tmp/tests-to-run + echo "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" > tags.txt + echo $(circleci tests split ./tags.txt) + circleci tests split ./tags.txt > /tmp/tests-to-run mix test --only $(cat /tmp/tests-to-run) - run: name: (Cabbage) Format generated code and check for warnings From c3d4fd5c1a929677e8df83b2a881b19d673e49fd Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 15:43:11 +0300 Subject: [PATCH 06/12] define tags in a separate file --- .circleci/config.yml | 1 - priv/cabbage | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index e7a2d0d3d1..7bde0dde4b 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -629,7 +629,6 @@ jobs: make install make generate_api_code mix deps.get - echo "configuration deposit fee in_flight_exit invalid_standard_exits service_name standard_exits transactions watcher_info_api watcher_status" > tags.txt echo $(circleci tests split ./tags.txt) circleci tests split ./tags.txt > /tmp/tests-to-run mix test --only $(cat /tmp/tests-to-run) diff --git a/priv/cabbage b/priv/cabbage index e11f8c26a0..753d50c877 160000 --- a/priv/cabbage +++ b/priv/cabbage @@ -1 +1 @@ -Subproject commit e11f8c26a0017318301392c7d768cd5655bf49c0 +Subproject commit 753d50c877f94f3780f273848c8aca2361d32286 From 9d6fb3520b725d06c081b176c5b39a78a65b110e Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 17:13:43 +0300 Subject: [PATCH 07/12] try using include --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7bde0dde4b..d487babc99 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -631,7 +631,7 @@ jobs: mix deps.get echo $(circleci tests split ./tags.txt) circleci tests split ./tags.txt > /tmp/tests-to-run - mix test --only $(cat /tmp/tests-to-run) + mix test --exclude test --include $(cat /tmp/tests-to-run) - run: name: (Cabbage) Format generated code and check for warnings command: | From e040d8b8a4005f9c6fdf0db48119003900936957 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 18:06:42 +0300 Subject: [PATCH 08/12] update submodule --- .circleci/config.yml | 2 +- priv/cabbage | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index d487babc99..7f8ea229ad 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -631,7 +631,7 @@ jobs: mix deps.get echo $(circleci tests split ./tags.txt) circleci tests split ./tags.txt > /tmp/tests-to-run - mix test --exclude test --include $(cat /tmp/tests-to-run) + mix test --exclude test $(cat /tmp/tests-to-run) - run: name: (Cabbage) Format generated code and check for warnings command: | diff --git a/priv/cabbage b/priv/cabbage index 753d50c877..64285e925a 160000 --- a/priv/cabbage +++ b/priv/cabbage @@ -1 +1 @@ -Subproject commit 753d50c877f94f3780f273848c8aca2361d32286 +Subproject commit 64285e925a667ed8765d4d2cc84d29a809bb84b2 From acace7511254b6f5f125eb0ccf69464f93f94722 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Mon, 21 Sep 2020 18:20:29 +0300 Subject: [PATCH 09/12] uncomment circle ci config --- .circleci/config.yml | 236 +++++++++++++++++++++---------------------- 1 file changed, 118 insertions(+), 118 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7f8ea229ad..96b6bb9fbd 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1004,123 +1004,123 @@ workflows: only: /.+/ tags: only: /.+/ - # - test_barebone_release: - # filters: *all_branches_and_tags - # - notify_services: - # requires: - # - increase_chart_version_watcher_master - # - increase_chart_version_watcher_info_master - # filters: - # branches: - # only: - # - master - # - coveralls_report: - # requires: - # - watcher_coveralls_and_integration_tests - # - watcher_info_coveralls_and_integration_tests - # - common_coveralls_and_integration_tests - # - test - # - watcher_coveralls_and_integration_tests: - # requires: [build] - # filters: *all_branches_and_tags - # - watcher_info_coveralls_and_integration_tests: - # requires: [build] - # filters: *all_branches_and_tags - # - common_coveralls_and_integration_tests: - # requires: [build] - # filters: *all_branches_and_tags + - test_barebone_release: + filters: *all_branches_and_tags + - notify_services: + requires: + - increase_chart_version_watcher_master + - increase_chart_version_watcher_info_master + filters: + branches: + only: + - master + - coveralls_report: + requires: + - watcher_coveralls_and_integration_tests + - watcher_info_coveralls_and_integration_tests + - common_coveralls_and_integration_tests + - test + - watcher_coveralls_and_integration_tests: + requires: [build] + filters: *all_branches_and_tags + - watcher_info_coveralls_and_integration_tests: + requires: [build] + filters: *all_branches_and_tags + - common_coveralls_and_integration_tests: + requires: [build] + filters: *all_branches_and_tags - test_docker_compose_release: filters: *all_branches_and_tags - # - test_docker_compose_performance: - # filters: *all_branches_and_tags - # - test_docker_compose_reorg: - # filters: *all_branches_and_tags - # - audit_deps: - # requires: [build] - # filters: *all_branches_and_tags - # - lint: - # requires: [build] - # filters: *all_branches_and_tags - # - lint_version: - # requires: [build] - # filters: *all_branches_and_tags - # - sobelow: - # requires: [build] - # filters: *all_branches_and_tags - # - dialyzer: - # requires: [build] - # filters: *all_branches_and_tags - # - test: - # requires: [build] - # filters: *all_branches_and_tags - # - property_tests: - # requires: [build] - # filters: *all_branches_and_tags - # - watcher_mix_based_childchain: - # filters: *all_branches_and_tags - # - publish_watcher: - # requires: - # [ - # test_barebone_release, - # test_docker_compose_release, - # watcher_coveralls_and_integration_tests, - # watcher_info_coveralls_and_integration_tests, - # common_coveralls_and_integration_tests, - # test, - # property_tests, - # dialyzer, - # lint, - # lint_version, - # audit_deps - # ] - # filters: &master_and_version_branches_and_all_tags - # branches: - # only: - # - master - # # vMAJOR.MINOR (e.g. v0.1, v0.2, v1.0, v2.1, etc.) - # - /^v[0-9]+\.[0-9]+/ - # tags: - # only: - # - /.+/ - # - publish_watcher_info: - # requires: - # [ - # test_barebone_release, - # test_docker_compose_release, - # watcher_coveralls_and_integration_tests, - # watcher_info_coveralls_and_integration_tests, - # common_coveralls_and_integration_tests, - # test, - # property_tests, - # dialyzer, - # lint, - # lint_version, - # audit_deps - # ] - # filters: *master_and_version_branches_and_all_tags - # # Increase chart version for master, this will end up trigger deployment on dev - # - increase_chart_version_watcher_master: - # requires: [publish_watcher, publish_watcher_info] - # filters: - # branches: - # only: - # - master - # - increase_chart_version_watcher_info_master: - # requires: [publish_watcher, publish_watcher_info] - # filters: - # branches: - # only: - # - master - # # Increase chart version for new release - # - increase_chart_version_watcher_release: - # requires: [publish_watcher, publish_watcher_info] - # filters: &only_release_tag - # branches: - # ignore: /.*/ - # tags: - # only: - # # eg. v1.0.3-pre.0, v1.0.3, ... - # - /^v[0-9]+\.[0-9]+\.[0-9]+.*/ - # - increase_chart_version_watcher_info_release: - # requires: [publish_watcher, publish_watcher_info] - # filters: *only_release_tag + - test_docker_compose_performance: + filters: *all_branches_and_tags + - test_docker_compose_reorg: + filters: *all_branches_and_tags + - audit_deps: + requires: [build] + filters: *all_branches_and_tags + - lint: + requires: [build] + filters: *all_branches_and_tags + - lint_version: + requires: [build] + filters: *all_branches_and_tags + - sobelow: + requires: [build] + filters: *all_branches_and_tags + - dialyzer: + requires: [build] + filters: *all_branches_and_tags + - test: + requires: [build] + filters: *all_branches_and_tags + - property_tests: + requires: [build] + filters: *all_branches_and_tags + - watcher_mix_based_childchain: + filters: *all_branches_and_tags + - publish_watcher: + requires: + [ + test_barebone_release, + test_docker_compose_release, + watcher_coveralls_and_integration_tests, + watcher_info_coveralls_and_integration_tests, + common_coveralls_and_integration_tests, + test, + property_tests, + dialyzer, + lint, + lint_version, + audit_deps + ] + filters: &master_and_version_branches_and_all_tags + branches: + only: + - master + # vMAJOR.MINOR (e.g. v0.1, v0.2, v1.0, v2.1, etc.) + - /^v[0-9]+\.[0-9]+/ + tags: + only: + - /.+/ + - publish_watcher_info: + requires: + [ + test_barebone_release, + test_docker_compose_release, + watcher_coveralls_and_integration_tests, + watcher_info_coveralls_and_integration_tests, + common_coveralls_and_integration_tests, + test, + property_tests, + dialyzer, + lint, + lint_version, + audit_deps + ] + filters: *master_and_version_branches_and_all_tags + # Increase chart version for master, this will end up trigger deployment on dev + - increase_chart_version_watcher_master: + requires: [publish_watcher, publish_watcher_info] + filters: + branches: + only: + - master + - increase_chart_version_watcher_info_master: + requires: [publish_watcher, publish_watcher_info] + filters: + branches: + only: + - master + # Increase chart version for new release + - increase_chart_version_watcher_release: + requires: [publish_watcher, publish_watcher_info] + filters: &only_release_tag + branches: + ignore: /.*/ + tags: + only: + # eg. v1.0.3-pre.0, v1.0.3, ... + - /^v[0-9]+\.[0-9]+\.[0-9]+.*/ + - increase_chart_version_watcher_info_release: + requires: [publish_watcher, publish_watcher_info] + filters: *only_release_tag From e0a102eb84732ad4889e8038a4e3dd7fa92fdf71 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Tue, 22 Sep 2020 10:45:25 +0300 Subject: [PATCH 10/12] grep moduletags --- .circleci/config.yml | 1 + priv/cabbage | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 96b6bb9fbd..4707c6cfce 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -629,6 +629,7 @@ jobs: make install make generate_api_code mix deps.get + grep -r "@moduletag" ./apps/itest/ | awk '{print "--include " $3}' | tr -d ':' > tags.txt echo $(circleci tests split ./tags.txt) circleci tests split ./tags.txt > /tmp/tests-to-run mix test --exclude test $(cat /tmp/tests-to-run) diff --git a/priv/cabbage b/priv/cabbage index 64285e925a..9f83fcfd55 160000 --- a/priv/cabbage +++ b/priv/cabbage @@ -1 +1 @@ -Subproject commit 64285e925a667ed8765d4d2cc84d29a809bb84b2 +Subproject commit 9f83fcfd5525d81b0fe9aa49c5d0cd7f5c79b85a From 537293efb58aa722df992ad1755ca7d820e37d81 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Tue, 29 Sep 2020 09:35:22 +0300 Subject: [PATCH 11/12] use master branch --- .gitmodules | 2 +- priv/cabbage | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitmodules b/.gitmodules index 139cd6ae10..ebb28fdad5 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,4 +1,4 @@ [submodule "priv/cabbage"] path = priv/cabbage url = https://github.com/omgnetwork/specs.git - branch = ayrat555/parallelize-tests + branch = master diff --git a/priv/cabbage b/priv/cabbage index 9f83fcfd55..f204689958 160000 --- a/priv/cabbage +++ b/priv/cabbage @@ -1 +1 @@ -Subproject commit 9f83fcfd5525d81b0fe9aa49c5d0cd7f5c79b85a +Subproject commit f204689958d712858ac16d69c2ddaedc4bb5b607 From 73b3000f2272bc67c7545a45e239f24da60a9533 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Tue, 29 Sep 2020 10:12:44 +0300 Subject: [PATCH 12/12] update submodule --- priv/cabbage | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/priv/cabbage b/priv/cabbage index f204689958..c127993c8d 160000 --- a/priv/cabbage +++ b/priv/cabbage @@ -1 +1 @@ -Subproject commit f204689958d712858ac16d69c2ddaedc4bb5b607 +Subproject commit c127993c8d0d8cf93c10461e342917a9520ca8ab