Open hkar19 opened 3 years ago
I am facing the same issue. Right now I am using the below way until I get a sample config. detox recorder --bundleId "com.example.myApp" --simulatorId booted --outputTestFile "~/Desktop/RecordedTest.js" --testName "My Recorded Test" --record
Also have this issue using .detoxrc.json
and not package.json
I've also verified the json is valid as mentioned in docs.
facing the same issues, any recommended fixes....?
Same here, cant run the recorder while using detoxrc.json
Same here. I think it a bug for DetoxRecorder. According to the document of Detox, we add the configuration in ".detoxrc.json", Please have a look @LeoNatan
I am no longer involved with this project or Wix. Thanks
is this project no longer maintained/updated?
any update ?
I am also facing the same issue. Any update?
Apparently this repo has been forsaken. last commit by any contributor to master was on 10 Feb 2021. Maybe we should play with another things?
I managed to make the recorder work on the iOS simulator.
package.json:
"detox": "^19.5.7", "detox-recorder": "^1.0.151",
.detoxrc.json:
{ "testRunner": "jest", "runnerConfig": "e2e/config.json", "skipLegacyWorkersInjection": true, "apps": { "ios.release": { "name": "yourproject", "type": "ios.app", "binaryPath": "ios/build/Build/Products/Release-iphonesimulator/yourproject.app", "build": "xcodebuild -workspace ios/yourproject.xcworkspace -scheme yourproject -configuration Release -sdk iphonesimulator -derivedDataPath ios/build" }, "ios.debug": { "name": "yourproject", "type": "ios.app", "binaryPath": "ios/build/Build/Products/Release-iphonesimulator/yourproject.app", "build": "xcodebuild -workspace ios/yourproject.xcworkspace -scheme yourproject -sdk iphonesimulator -derivedDataPath ios/build" }, "android.debug": { "type": "android.apk", "binaryPath": "android/app/build/outputs/apk/debug/app-debug.apk", "build": "cd android && ./gradlew assembleDebug assembleAndroidTest -DtestBuildType=debug && cd .." }, "android.release": { "type": "android.apk", "binaryPath": "android/app/build/outputs/apk/release/app-release.apk", "build": "cd android && ./gradlew assembleRelease assembleAndroidTest -DtestBuildType=release && cd .." } }, "devices": { "simulator": { "type": "ios.simulator", "device": { "type": "iPhone 11" } }, "emulator": { "type": "android.emulator", "device": { "avdName": "Pixel_2_API_30" } } }, "configurations": { "ios.sim.release": { "device": "simulator", "app": "ios.release" }, "ios.sim.debug": { "device": "simulator", "app": "ios.debug" }, "android.emu.debug": { "device": "emulator", "app": "android.debug" }, "android.emu.release": { "device": "emulator", "app": "android.release" } } }
Build and run your project in Xcode with simulator iOS 13.7. (I experienced crashes with iOS 15 and 12)
Then type in your React Native project:
detox recorder -b org.reactjs.native.example.yourproject -s booted -o "./yourtestcase.js" --record
Same issue + 1
This does seem to not work, regardless of .detoxrc.json or package.json. Trying to run on an already active simulator does seem to start the app but then immediately crashes. The js file gets created but obviously contains no tests.
Do we have any pointers as to what might be causing this?
I managed to make the recorder work on the iOS simulator.
package.json:
"detox": "^19.5.7", "detox-recorder": "^1.0.151",
.detoxrc.json:
{ "testRunner": "jest", "runnerConfig": "e2e/config.json", "skipLegacyWorkersInjection": true, "apps": { "ios.release": { "name": "yourproject", "type": "ios.app", "binaryPath": "ios/build/Build/Products/Release-iphonesimulator/yourproject.app", "build": "xcodebuild -workspace ios/yourproject.xcworkspace -scheme yourproject -configuration Release -sdk iphonesimulator -derivedDataPath ios/build" }, "ios.debug": { "name": "yourproject", "type": "ios.app", "binaryPath": "ios/build/Build/Products/Release-iphonesimulator/yourproject.app", "build": "xcodebuild -workspace ios/yourproject.xcworkspace -scheme yourproject -sdk iphonesimulator -derivedDataPath ios/build" }, "android.debug": { "type": "android.apk", "binaryPath": "android/app/build/outputs/apk/debug/app-debug.apk", "build": "cd android && ./gradlew assembleDebug assembleAndroidTest -DtestBuildType=debug && cd .." }, "android.release": { "type": "android.apk", "binaryPath": "android/app/build/outputs/apk/release/app-release.apk", "build": "cd android && ./gradlew assembleRelease assembleAndroidTest -DtestBuildType=release && cd .." } }, "devices": { "simulator": { "type": "ios.simulator", "device": { "type": "iPhone 11" } }, "emulator": { "type": "android.emulator", "device": { "avdName": "Pixel_2_API_30" } } }, "configurations": { "ios.sim.release": { "device": "simulator", "app": "ios.release" }, "ios.sim.debug": { "device": "simulator", "app": "ios.debug" }, "android.emu.debug": { "device": "emulator", "app": "android.debug" }, "android.emu.release": { "device": "emulator", "app": "android.release" } } }
Build and run your project in Xcode with simulator iOS 13.7. (I experienced crashes with iOS 15 and 12)
Then type in your React Native project:
detox recorder -b org.reactjs.native.example.yourproject -s booted -o "./yourtestcase.js" --record
I was able to use Detrox Recorder. I've used simulator iOS 14.5 (iPhone 12) (I've experienced crashes with iOS 15 and 16)
Describe the Bug I cannot run
detox recorder --configuration debug:ios --outputTestFile "~/Desktop/RecordedTest.js" --testName "My Recorded Test" --record
as it shows error:
Key “device” either not found or in unsupported format as found in package.json for the “debug:ios” configuration.
my
.detoxrc.json
where did i do wrong?
To Reproduce i run
detox recorder --configuration debug:ios --outputTestFile "~/Desktop/RecordedTest.js" --testName "My Recorded Test" --record
Expected Behavior it run
Actual Behavior it shows error