razorpay / razorpay-pod

:iphone: CocoaPod implementation of Razorpay's Payment SDK. Refer for instructions:
https://docs.razorpay.com/v1/page/ios-integration
MIT License
22 stars 18 forks source link

Error reporting test coverage in Xcode 14.3.1 and above. #195

Open abhijeetchoudhary1mg opened 11 months ago

abhijeetchoudhary1mg commented 11 months ago

Description

Error reporting test coverage in Xcode when razor-pay pod is installed.

Razorpay pod Version :

1.3.2 and 1.3.4

Xcode Version :

14.3.1 and 15.0

What you did:

Using 'razorpay-pod' in native iOS project.

What happened:

Xcode is throwing error when trying to generate unit test coverage. Failed to merge raw profiles in directory /{my project dir}/DerivedData/{my project name}/Build/ProfileData/A98EC493-3AB4-4B1C-B7FC-BC5D77B23EE3 to destination /{my project dir}/DerivedData/{my project name}/Build/ProfileData/A98EC493-3AB4-4B1C-B7FC-BC5D77B23EE3/Coverage.profdata: Aggregation tool '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/llvm-profdata' failed with exit code 1: warning: /{my project dir}/DerivedData/{my project name}/Build/ProfileData/A98EC493-3AB4-4B1C-B7FC-BC5D77B23EE3/997F01E3-3735-4897-AE00-31EBB0A9E8D3-57885.profraw: invalid instrumentation profile data (file header is corrupt) error: no profile can be merged

Steps To Reproduce

Provide a detailed list of steps that reproduce the issue.

  1. Install 'razorpay-pod' in an xcode iOS project.
  2. Run Unit Test
  3. Check Unit Test Coverage
ramprasadAnand commented 11 months ago

@abhijeetchoudhary1mg can you please share more detailed error logs which indicates the error caused due to razorpay-pod framework integration in your project.

abhijeetchoudhary1mg commented 11 months ago

@ramprasadAnand I'm sharing a project with similar issues. In this, you can go through the detailed logs and reproduce issues using the steps mentioned in the description.

https://github.com/abhijeetchoudhary1mg/sample

SuryakantRapido commented 7 months ago

Any update on this ?

vivekshindhe commented 7 months ago

We figured out that the issue was happening because the xcframework generated was with toolchains older than 15. This has been fixed in the later versions. @SuryakantRapido

SURYAKANTSHARMA commented 7 months ago

what is fix version ? Is it release or yet to be released ? It is blocking our coverage reporting hence the question.

xcframework generated was with toolchains older than 15

what is 15 signify here ? is this xcode version ?

swayambhu-banerjee commented 4 months ago

We're encountering a similar issue, and it's currently blocking the generation of our Test Case coverage report. Could you please provide an update on this?

We're using SDK version 1.3.7 and Xcode version 15.3.

P:S: This is working fine when used by pod but issue is occurring when we are using it with SPM.