Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash when running UITests on Real Device #371

Open
6 of 9 tasks
mrunal-thanki opened this issue May 31, 2024 · 0 comments
Open
6 of 9 tasks

Crash when running UITests on Real Device #371

mrunal-thanki opened this issue May 31, 2024 · 0 comments

Comments

@mrunal-thanki
Copy link

New Issue Checklist

Environment

  • version of OHHTTPStubs: [LIB VERSION HERE]
  • integration method you are using:
    • Cocoapods
    • Carthage
    • submodule
    • other
  • version of the tool you use: OHHTTPStubs (9.1.0)
  • version of iOS Device : 17.4.1

Issue Description

When I'm running UITests on simulator, it's working fine and executing all the tests. But when tried running on device its causing issue for file access for stub files(mock json files).

Complete output when you encounter the issue (if any)
*** Assertion failure in -[HTTPStubsResponse initWithFileURL:statusCode:headers:], HTTPStubsResponse.m:176
*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '-[HTTPStubsResponse initWithFileURL:statusCode:headers:] Couldn't get the file size for URL. The URL was: file:///var/containers/Bundle/Application/A8FBF3B7-0F52-4E8B-AE8E-D93A907B34B7/InstallUITests-Runner.app/PlugIns/InstallUITests.xctest/get_jwk_success.json. The operation to retrieve the file size was unsuccessful. The error associated with that operation was: Error Domain=NSCocoaErrorDomain Code=257 "The file “get_jwk_success.json” couldn’t be opened because you don’t have permission to view it." UserInfo={NSURL=file:///var/containers/Bundle/Application/A8FBF3B7-0F52-4E8B-AE8E-D93A907B34B7/InstallUITests-Runner.app/PlugIns/InstallUITests.xctest/get_jwk_success.json, NSFilePath=/var/containers/Bundle/Application/A8FBF3B7-0F52-4E8B-AE8E-D93A907B34B7/InstallUITests-Runner.app/PlugIns/InstallUITests.xctest/get_jwk_success.json, NSUnderlyingError=0x3010233c0 {Error Domain=NSPOSIXErrorDomain Code=1 "Operation not permitted"}}'
*** First throw call stack:
(0x19b7d6b28 0x193632f78 0x19ac3b920 0x103111a08 0x1031115f0 0x100fdf428 0x100fdcc9c 0x100fdcc24 0x103112b30 0x10310e2f4 0x19c833878 0x1a35e6dd4 0x1a35ea86c 0x19ca7bab0 0x19b70eb34 0x19ca7b9a0 0x19ca7e084 0x19b72162c 0x19b7208a8 0x19b71f058 0x19b71dd88 0x19b71d968 0x19ca7cc48 0x19a61da9c 0x1f76cda90 0x1f76ccfcc)
libc++abi: terminating due to uncaught exception of type NSException
@mrunal-thanki mrunal-thanki changed the title App crash when running UITests on Real Device Crash when running UITests on Real Device May 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant