From 6c7c004ae65fdc5434c8e2eb5d9d44b04c340060 Mon Sep 17 00:00:00 2001 From: Kenneth Kwakye-Gyamfi <59402430+cross19xx@users.noreply.github.com> Date: Wed, 30 Sep 2020 09:44:27 +0000 Subject: [PATCH] chore: Update CircleCI to run examples (#557) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * chore: Update CircleCI to run examples * chore: loop through each example and run test * fix: switch to using yarn instead of npm * Update .circleci/config.yml Co-authored-by: Michał Pierzchała --- .circleci/config.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 16c49f96..e31d6ec1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -65,6 +65,13 @@ jobs: at: ~/react-native-testing-library - run: | cd website && yarn install && yarn build + test-examples: + <<: *defaults + steps: + - attach_workspace: + at: ~/react-native-testing-library + - run: | + ls -d ./examples/* | xargs -I {} bash -c "cd '{}' && yarn install && yarn test" deploy-website: <<: *defaults steps: @@ -96,6 +103,10 @@ workflows: - install-dependencies # docusuarus build is running when deploying website as well filters: *filter-ignore-master + - test-examples: + requires: + - install-dependencies + filters: *filter-only-master - deploy-website: requires: - install-dependencies