Brightify / Cuckoo

Boilerplate-free mocking framework for Swift!
MIT License
1.67k stars 175 forks source link

Mocks with omitted argument labels are not created #422

Closed klein-artur closed 2 years ago

klein-artur commented 2 years ago

Let's say I have a class like this:

class SomeClass {
    func someFunc(_ someParam: Int) {
        someCode()
    }
}

If such a file is in the list of mock objects, the generation script fails. The output is terminated with signal 5; aborting

zivadler commented 2 years ago

same here but for us failed with signal 4

Showing Recent Messages xargs: cuckoo_generator: terminated with signal 4; aborting

Command PhaseScriptExecution failed with a nonzero exit code

MatyasKriz commented 2 years ago

This is probably caused by the new Xcode's SourceKit, I'll see what I can do.

zivadler commented 2 years ago

the signal 4 error we got is only when using Xcode 13.3+ but when using Xcode 13.2 is working fine. the solution we did for Xcode 13.3+ is "I had to download the latest cuckoo_generator 1.7.1, commit to my repository. I was then able to build and run specs on Xcode 13.3.x" as explained here: https://github.com/Brightify/Cuckoo/issues/417

MatyasKriz commented 2 years ago

I see, I thought that this error seemed familiar. Yeah, it's fixed in version 1.7.1, but you absolutely don't have to commit the binary into your repo, simply add --clean to the run script to make it build/download the newest binary.

I'll close this issue now, thanks @zivadler for reminding me, though just to reiterate, committing to repository is definitely not necessary and unless you use Git LFS for it, you're gonna bloat your repository.