Tyler-Keith-Thompson / CucumberSwift

A lightweight swift Cucumber implementation
https://tyler-keith-thompson.github.io/CucumberSwift/documentation/cucumberswift/
MIT License
74 stars 19 forks source link

"GeneratedUnImplementedSteps" attachment in pending steps is not getting generated #100

Open naveenkosuri opened 2 months ago

naveenkosuri commented 2 months ago

GeneratedUnImplementedSteps is not getting generated in pending steps, I even tried in CucumnberSwiftSample application

To Reproduce Followed all steps in the getting started page using swiftpackagemanager

Expected behavior should generated a swift file with pending steps.

Screenshots IMG_8534

Additional context Add any other context about the problem here.

naveenkosuri commented 2 months ago

@Tyler-Keith-Thompson could you please look into this

ianhlavats commented 2 months ago

I've seen this issue happen too and I noticed the following error in my build logs:

Details: Error writing attachment data to file Error Domain=NSCocoaErrorDomain Code=514 "The item couldn’t be saved because the file name “” is invalid." UserInfo={NSFilePath=, NSUnderlyingError=0x600002409500 {Error Domain=NSPOSIXErrorDomain Code=63 "File name too long"}} Object:   <IDESchemeActionTestAttachment: 0x600005b34380>

07-Jul-2024 08:46:40 | [09:46:40]: ▸ Method:   -_savePayload: 07-Jul-2024 08:46:40 | [09:46:40]: ▸ Thread:   <_NSMainThread: 0x6000020501c0>{number = 1, name = main} 07-Jul-2024 08:46:40 | [09:46:40]: ▸ Please file a bug at https://feedbackassistant.apple.com with this warning message and any useful information you can provide.

It looks like the filename containing the generated steps is too long and Xcode bails on writing the attachment.

I tested this on Xcode 15.4.