From 0b9b92f281bcfbe0efa4eacaf746457389202161 Mon Sep 17 00:00:00 2001 From: Asaf Korem Date: Mon, 6 Jan 2025 16:06:03 +0200 Subject: [PATCH] test: change skip method to skip only on iOS. --- detox/test/e2e/17.datePicker.test.js | 2 +- detox/test/e2e/17.picker.test.js | 2 +- detox/test/e2e/copilot/09.copilot.datepicker.test.js | 2 +- detox/test/e2e/utils/custom-describes.js | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/detox/test/e2e/17.datePicker.test.js b/detox/test/e2e/17.datePicker.test.js index f8bab7608a..2f59ae6097 100644 --- a/detox/test/e2e/17.datePicker.test.js +++ b/detox/test/e2e/17.datePicker.test.js @@ -1,6 +1,6 @@ const jestExpect = require('expect').default; -describe.skipIfNewArch('DatePicker', () => { +describe.skipIfNewArchOnIOS('DatePicker', () => { describe.each([ ['ios', 'compact', 0], ['ios', 'inline', 1], diff --git a/detox/test/e2e/17.picker.test.js b/detox/test/e2e/17.picker.test.js index a2cd329b39..258d448ebf 100644 --- a/detox/test/e2e/17.picker.test.js +++ b/detox/test/e2e/17.picker.test.js @@ -1,4 +1,4 @@ -describe.skipIfNewArch(":ios: Picker", () => { +describe.skipIfNewArchOnIOS(":ios: Picker", () => { beforeEach(async () => { await device.reloadReactNative(); await element(by.text("Picker")).tap(); diff --git a/detox/test/e2e/copilot/09.copilot.datepicker.test.js b/detox/test/e2e/copilot/09.copilot.datepicker.test.js index 6d12f16d05..afba3912e0 100644 --- a/detox/test/e2e/copilot/09.copilot.datepicker.test.js +++ b/detox/test/e2e/copilot/09.copilot.datepicker.test.js @@ -1,6 +1,6 @@ const { default: jestExpect } = require('expect'); -describe.skipIfNewArch('DatePicker', () => { +describe.skipIfNewArchOnIOS('DatePicker', () => { describe.forCopilot('Copilot', () => { beforeEach(async () => { await copilot.perform( diff --git a/detox/test/e2e/utils/custom-describes.js b/detox/test/e2e/utils/custom-describes.js index a42898101b..ee0013e348 100644 --- a/detox/test/e2e/utils/custom-describes.js +++ b/detox/test/e2e/utils/custom-describes.js @@ -6,9 +6,9 @@ describe.skipIfCI = (title, fn) => { return isCI ? describe.skip(title, fn) : describe(title, fn); }; -describe.skipIfNewArch = (title, fn) => { +describe.skipIfNewArchOnIOS = (title, fn) => { const isNewArch = process.env.RCT_NEW_ARCH_ENABLED === '1'; - if (isNewArch) { + if (isNewArch && device.getPlatform() === 'ios') { console.warn('Skipping tests for new architecture, as there are issues related to the new architecture.'); return describe.skip(title, fn); }