From 81203afd3c5a9d1f59bfd1926cd12a83dd4af70c Mon Sep 17 00:00:00 2001 From: Nhi Nguyen Date: Thu, 27 Sep 2018 09:32:50 -0700 Subject: [PATCH] Send notifications on e2e test failures --- .circleci/config.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 758da358..c7defac1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,4 +1,13 @@ version: 2 + +_run: + notify_on_fail: ¬ify_on_fail + when: on_fail + command: | + wget https://raw.githubusercontent.com/segmentio/circleci-notifications/master/slack-notify-branch.sh + chmod u+x slack-notify-branch.sh + BUILD_STATUS="Failed" NOTIFY_BRANCH="master scheduled_e2e_testing" ./slack-notify-branch.sh + jobs: build: working_directory: /temp @@ -38,7 +47,7 @@ jobs: - run: dotnet test Test/Test.csproj test_20: working_directory: /test20 - docker: + docker: - image: microsoft/dotnet:2.0-sdk environment: DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 @@ -85,6 +94,8 @@ jobs: - run: dotnet restore Test.E2E/Test.E2E.csproj - run: dotnet build Test.E2E/Test.E2E.csproj - run: cd Test.E2E/ && ./e2e.sh + - run: *notify_on_fail + workflows: version: 2 build_and_test: