From 498cf7e2d7c6888e5a049c94e9f72f4676d528b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9ctor=20Ramos?= Date: Sun, 4 Mar 2018 18:10:29 -0800 Subject: [PATCH] =?UTF-8?q?Re=C3=ABnable=20iOS=20and=20tvOS=20tests?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Summary: Although the test suites have a handful of failing tests, the jobs themselves do not fail. Let's get these tests back into the fold so that we may track our progress getting these back to a good state. cc dlowder-salesforce Run tests on Circle, and confirm everything is green: https://circleci.com/workflow-run/4dd1a84b-502d-4ad6-aa41-64c768392a6b If you go into the test iOS and test tvOS jobs, you will see that we are collecting test results at the top. These results show the failing individual tests. Closes https://github.com/facebook/react-native/pull/18171 Differential Revision: D7151558 Pulled By: hramos fbshipit-source-id: f105ec8bc97e80ed1b8358cde3f13a1ad3b271c2 --- .circleci/config.yml | 87 +++++++++----------------------------------- scripts/objc-test.sh | 6 --- 2 files changed, 18 insertions(+), 75 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2cfbaf4f6..1b75edce4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -211,27 +211,27 @@ aliases: mkdir -p ~/react-native/reports/junit/ - &build-objc-ios-test-app - name: Build Objective-C iOS Test App + name: Build iOS Test App command: ./scripts/objc-test-ios.sh - &run-objc-ios-tests - name: Objective-C iOS Test Suite + name: iOS Test Suite command: ./scripts/objc-test-ios.sh test - &build-objc-tvos-test-app - name: Build Objective-C tvOS Test App + name: Build tvOS Test App command: ./scripts/objc-test-tvos.sh - &run-objc-tvos-tests - name: Objective-C tvOS Test Suite + name: tvOS Test Suite command: ./scripts/objc-test-tvos.sh test - &run-objc-ios-e2e-tests - name: Objective-C iOS End-to-End Test Suite + name: iOS End-to-End Test Suite command: node ./scripts/run-ci-e2e-tests.js --ios --js --retries 3; - &run-objc-tvos-e2e-tests - name: Objective-C tvOS End-to-End Test Suite + name: tvOS End-to-End Test Suite command: node ./scripts/run-ci-e2e-tests.js --tvos --js --retries 3; defaults: &defaults @@ -292,8 +292,6 @@ jobs: - store_test_results: path: ~/react-native/reports/junit - - store_artifacts: - path: ~/react-native/reports/junit - store_artifacts: path: ~/react-native/yarn.lock @@ -308,8 +306,6 @@ jobs: - store_test_results: path: ~/react-native/reports/junit - - store_artifacts: - path: ~/react-native/reports/junit # Runs JavaScript tests on Node 6 test_javascript_node6_compatibility: @@ -328,83 +324,47 @@ jobs: - store_test_results: path: ~/react-native/reports/junit - - store_artifacts: - path: ~/react-native/reports/junit - - # Builds iOS test app - build_objc_ios_test_app: - <<: *macos_defaults - dependencies: - pre: - - xcrun instruments -w "iPhone 5s (11.1)" || true - steps: - - attach_workspace: - at: ~/react-native - - - run: *build-objc-ios-test-app # Runs unit tests on iOS devices - test_objc_ios: + test_ios: <<: *macos_defaults - dependencies: - pre: - - xcrun instruments -w "iPhone 5s (11.1)" || true steps: - attach_workspace: at: ~/react-native + - run: xcrun instruments -w "iPhone 5s (11.1)" || true + - run: brew install watchman - run: *run-objc-ios-tests - store_test_results: path: ~/react-native/reports/junit - - store_artifacts: - path: ~/react-native/reports/junit - - # Builds tvOS test app - build_objc_tvos_test_app: - <<: *macos_defaults - dependencies: - pre: - - xcrun instruments -w "Apple TV 1080p (11.1)" || true - steps: - - attach_workspace: - at: ~/react-native - - - run: *build-objc-tvos-test-app # Runs unit tests on tvOS devices - test_objc_tvos: + test_tvos: <<: *macos_defaults - dependencies: - pre: - - xcrun instruments -w "Apple TV 1080p (11.1)" || true steps: - attach_workspace: at: ~/react-native + - run: xcrun instruments -w "Apple TV 1080p (11.1)" || true + - run: brew install watchman - run: *run-objc-tvos-tests - store_test_results: path: ~/react-native/reports/junit - - store_artifacts: - path: ~/react-native/reports/junit # Runs end to end tests - test_objc_ios_e2e: + test_ios_e2e: <<: *macos_defaults - dependencies: - pre: - - xcrun instruments -w "iPhone 5s (11.1)" || true steps: - attach_workspace: at: ~/react-native + - run: xcrun instruments -w "iPhone 5s (11.1)" || true - run: *run-objc-ios-e2e-tests - store_test_results: path: ~/react-native/reports/junit - - store_artifacts: - path: ~/react-native/reports/junit # Checks podspec test_podspec: @@ -523,8 +483,6 @@ jobs: - run: *collect-android-test-results - store_test_results: path: ~/react-native/reports/junit - - store_artifacts: - path: ~/react-native/reports/junit # Analyze pull request and raise any lint/flow issues. @@ -604,18 +562,18 @@ workflows: requires: - checkout_code - # Build iOS & tvOS test apps - - build_objc_ios_test_app: + # Test iOS & tvOS + - test_ios: filters: *filter-ignore-gh-pages requires: - checkout_code - - build_objc_tvos_test_app: + - test_tvos: filters: *filter-ignore-gh-pages requires: - checkout_code # End-to-end tests - - test_objc_ios_e2e: + - test_ios_e2e: filters: *filter-ignore-gh-pages requires: - checkout_code @@ -657,15 +615,6 @@ workflows: # # The following were DISABLED because they have not run since # # the migration from Travis, and they have broken since then, - # # Test iOS & tvOS - # - test_objc_ios: - # filters: *filter-ignore-gh-pages - # requires: - # - checkout_code - # - test_objc_tvos: - # filters: *filter-ignore-gh-pages - # requires: - # - checkout_code # # CocoaPods # - test_podspec: # filters: *filter-ignore-gh-pages diff --git a/scripts/objc-test.sh b/scripts/objc-test.sh index 81614c5f6..f2c045998 100755 --- a/scripts/objc-test.sh +++ b/scripts/objc-test.sh @@ -73,9 +73,6 @@ curl 'http://localhost:8081/IntegrationTests/RCTRootViewIntegrationTestApp.bundl rm temp.bundle # Run tests -# TODO: We use xcodebuild because xctool would stall when collecting info about -# the tests before running them. Switch back when this issue with xctool has -# been resolved. xcodebuild \ -project "RNTester/RNTester.xcodeproj" \ -scheme $SCHEME \ @@ -87,9 +84,6 @@ xcodebuild \ else # Don't run tests. No need to pass -destination to xcodebuild. -# TODO: We use xcodebuild because xctool would stall when collecting info about -# the tests before running them. Switch back when this issue with xctool has -# been resolved. xcodebuild \ -project "RNTester/RNTester.xcodeproj" \ -scheme $SCHEME \