Detox

Gray box end-to-end testing and automation framework for mobile apps

MIT License

Downloads
1.1M
Stars
10.9K
Committers
260

Bot releases are hidden (Show)

Detox - 19.1.0

Published by noomorph almost 3 years ago

Deprecations

Affects only multi-app users. #3038 deprecates the unfortunate solution with { permanent: boolean } (see #2990) and suggests using device.appLaunchArgs.shared editor instead:

-device.appLaunchArgs.modify({ multiAppParameter: 'value' }, { permanent: true });
+device.appLaunchArgs.shared.modify({ multiAppParameter: 'value' });

Detox will be printing a warning if you use the deprecated signature:

detox[11948] WARN:  Detected an attempt to use device.launchArgs.modify(...) with a deprecated 'options' parameter.
Please use device.appLaunchArgs.shared.modify(...) instead.
For more details, see the reference at: https://wix.github.io/Detox/docs/api/device-object-api#deviceapplaunchargs

Types

  • Adds device.captureViewHierarchy() typings (#3061, @noomorph)
Detox - 19.0.0

Published by d4vidi almost 3 years ago

ℹ️ This is not a breaking release!

... at least not for the standard user.
Detox's version was major-bumped to 19 due to its potential breaking of 3rd party Detox-driver projects.
For complete information, refer to our migration guide.

Detox - 18.23.1

Published by jonathanmos almost 3 years ago

Fixes:

  • Update fishhook dependency to the latest version (#3027, @asafkorem, @calebmackdavenport).
Detox -

Published by noomorph about 3 years ago

Fixes:

  • types: add deprecated information (#2974, @mironiasty)
Detox - 18.22.2

Published by jonathanmos about 3 years ago

Fixes:

  • Kotlin classes missing after release build (#3010, @punksta, @jonathanmos)
  • Update COSTouchVisualizer URL (#3007, @calebmackdavenport)
Detox - 18.22.1

Published by d4vidi about 3 years ago

Fixes:

  • (typescript types) optional longPress duration (#3004, @noomorph)
  • Fix adb install for Android API < 23 (#2964, @david50407)
Detox - 18.22.0

Published by alon-ha about 3 years ago

Starting this release, Detox properly supports iOS v15 💪🏻


Fixes

  • iOS. Resolve UIWindowScene _keyWindowScene issue with iOS 15 (#2992)
Detox -

Published by noomorph about 3 years ago

Features

  • feat: CLI and JS config parity (#2965, @noomorph)

Previously you could override these options only via command line arguments. Now you can modify them via JS/JSON configs:

  interface DetoxAndroidEmulatorDriverConfig extends DetoxSharedAndroidDriverConfig {
      type: 'android.emulator';
      device: string | { avdName: string };
+     bootArgs?: string;
+     gpuMode?: 'auto' | 'host' | 'swiftshader_indirect' | 'angle_indirect' | 'guest';
+     headless?: boolean;
+     readonly?: boolean;
  }

  interface DetoxSharedAndroidDriverConfig {
+     forceAdbInstall?: boolean;
      utilBinaryPaths?: string[];
  }
    
  interface DetoxIosSimulatorDriverConfig {
    type: 'ios.simulator';
    device: string | Partial<IosSimulatorQuery>;
+   bootArgs?: string;
  }
  • feat(device): add .permanent option to app launch args (#2990, @noomorph)

Now you can persist app launch args between device.selectApp(name) calls, e.g.:

device.appLaunchArgs.modify({ ourMockServerPort: 9999 }, { permanent: true });
await device.selectApp('app2');
device.appLaunchArgs.get(); // { ourMockServerPort: 9999 }

Deprecations

  • CLI: avoid using --device-launch-args if you already do – use --device-boot-args instead. Otherwise, you'll be seeing deprecation warnings
Detox - 18.20.4

Published by d4vidi about 3 years ago

  • Add support for launch argument detoxURLBlacklistRegex on Android (#2911, @jonathanmos)
Detox - 18.20.3

Published by noomorph about 3 years ago

This release fixes handling of a couple of edge cases in Detox:

Fixes

  • iOS. Relocate (rescue) app-contained artifacts before the app uninstall (#2958, #2961, @noomorph)
  • Device API. Allow launching an app using just bundleId explicitly (#2960, @noomorph)
Detox - 18.20.2

Published by d4vidi about 3 years ago

Fixes

  • Fix issues with Android when running on SDK<23 (#2922, @mnightingale, @jonathanmos)
Detox - 18.20.1

Published by d4vidi about 3 years ago

Fixes:

  • ⚠️ (Detox CLI) Reverted: is installed globally check (#2925)
    Note: This reopens #2750!
  • (Android) Align device.id for Genymotion, with ext-api contract (#2915, d4vidi)
Detox - 18.20.0

Published by noomorph about 3 years ago

Android

  • Feature. Added adjustSliderToPosition and toHaveSliderPosition (#2888, @jonathanmos)
await element(by.id('slider')).adjustSliderToPosition(0.75);
await expect(element(by.id('slider'))).toHaveSliderPosition(0.75);
await expect(element(by.id('slider'))).toHaveSliderPosition(0.74, 0.1);
  • Feature. Added details of network busy resources (#2841, @jonathanmos)
detox[38329] INFO:  [APP_STATUS] App synchronization debug:
The app is busy, due to:
         - In-flight network activity
Details:
         - [http://localhost:9001/delay/3000]
  • Performance\Feature. Improved scroll speed and added scrollToIndex (#2854, @jonathanmos)
await element(by.id('scrollView')).scrollToIndex(0);
  • Fix. Stabilized emulator shutdown-boot between test suites when using -u, --cleanup CLI option (#2892, @noomorph)
  • Fix. Expand exemption rules related to Kotlin, in proguard-rules-app.pro (#2837 @d4vidi)

General

  • Feature. More detailed Detox config trace output (#2910, @noomorph)
  • Feature. Added -i option to cli to execute the build command only if the app binary is missing (#2913, @noomorph)
  • Fix. Earlier, if booting a device had been failing with an unexpected error, later on, that device was erroneusly considered as "busy" until the very end of such a test session. That resulted in the flooding of new devices, while the boot problem could have been transient. The fix should be especially helpful with --retries <N> option (#2900, @noomorph)
  • Performance. Avoid reinstalls of the same app binaries in multi-app configurations upon device initialization (#2907, @noomorph).
Detox -

Published by noomorph over 3 years ago

This release brings a few improvements to Detox configuration.

Features

  • Relative module paths in extends: ... (#2870, @noomorph)

The extends clause behavior has been documented for relative module paths and aligned to a commonly expected require(...) behavior:

{
  "extends": "../someDir/someBaseDetoxConfig"
}
  • skipLegacyWorkersInjection: true (#2872, @noomorph)

When added to a Detox config, it makes detox test command omit permanent --workers 1 CLI arg passed to Jest by default. This way, you can control your default workers count value programmatically in your Jest config via maxWorkers: <count> option. Thanks to @cdavie-weconnect for the initial idea.

Detox - 18.18.1

Published by d4vidi over 3 years ago

Fixes

  • Android: Add some allegedly missing Kotlin minification rules (#2852, @d4vidi)
  • iOS: waitFor + element().atIndex(): atIndex matcher ignored (#2850, @noomorph)
Detox -

Published by noomorph over 3 years ago

Feature parity between Android and iOS is an important goal for Detox, and today we have a few long-awaited feature requests for Android implemented in this release by @emilisb and @jonathanmos. 🎉

Features

  • Android: device.setLocation(...) support (#2783, by @emilisb)
  • Android: expect(...).toBeFocused() support (#2822, by @jonathanmos)

Fixes

  • Android: device.disableSynchronization() disables all synchronizations, i.e. not only the network (#2836, @jonathanmos)
  • Genymotion Cloud (beta): fix device allocation and locking strategy (#2845, @noomorph)
Detox -

Published by noomorph over 3 years ago

Detox

  • build(android): upgrade Espresso: 3.2.0->3.3.0 (latest stable) (#2816, @d4vidi)

Note: If you're using Detox but happen to have direct dependencies in Espresso (in your Gradle scripts), please remove them:

// app/build.gradle

dependencies {
-  androidTestImplementation 'androidx.test.ext:junit:1.1.2'
-  androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0
}
  • dx: fix stack traces for device.*() calls (#2826, @noomorph)
  • fix(ios): suppress redundant stderr logs on --record-videos all for Xcode 12.4+ (#2829, @noomorph)

Detox Native (Android)

  • feat: add distance-based scrolling API's to detox-native (#2824, @d4vidi)
Detox -

Published by noomorph over 3 years ago

Features

  • feat(ios): element(...).takeScreenshot() iOS API-parity with Android's (#2795, by @alon-ha)

Fixes

  • fix(jest): added compatibility with ^27.0.0 (#2812) @noomorph
  • fix(config): improved error message on configuration errors (#2800, #2814, by @noomorph)
  • types: add (un)reverseTcpPort to device (#2804, by @noomorph)

Miscalleneous

  • Artifacts: rename device log artifact from process.log to device.log (#2813, by @d4vidi)
Detox -

Published by d4vidi over 3 years ago

Features

  • We now properly support React Native 0.64, on Android (iOS work still pending). Minimal SDK changed to 21, accordingly. (#2805).
Detox -

Published by noomorph over 3 years ago

Fixes

  • hotfix(detox-cli): do not check -g on win32 (@noomorph, #2794)

Fixes this blocker on Windows platforms:

Error: "detox-cli" package is not meant to be installed locally, exiting...
HINT: Remove the local installation and reinstall it globally:
  npm uninstall detox-cli
  npm install -g detox-cli
Package Rankings
Top 0.61% on Npmjs.org
Top 3.86% on Proxy.golang.org
Top 21.46% on Repo1.maven.org
Badges
Extracted from project README
SWUbanner NPM Version NPM Downloads Build status Coverage Status Detox is released under the MIT license PR's welcome! Discord Twitter Follow
Related Projects