Nocilla icon indicating copy to clipboard operation
Nocilla copied to clipboard

Nullability annotations

Open pcantrell opened this issue 8 years ago • 5 comments

This adds annotations necessary for normal usage on Swift 3. Without these, code must deal with null values that Nocilla never actually returns, i.e. lots of ? interspersed in Nocilla DSL calls.

I haven’t been able to find an Obj-C annotation that gets rid of unused value warnings for the returned function pointers Nocilla uses. In Swift 3, it’s necessary to do this:

_ = stubRequest(...)

pcantrell avatar Sep 03 '16 15:09 pcantrell

Hmm, looks like this only compiles under Xcode 8. This can certainly wait for it to go GM.

pcantrell avatar Sep 03 '16 15:09 pcantrell

Thanks for doing this @pcantrell . We recently updated our tests to Swift3, I forked off this branch for any Swift 3 related changes we'd end up needing to make, and you pretty much caught everything that was hitting us with this. I only ended up making one change:

https://github.com/RobotsAndPencils/Nocilla/commit/b278fdd377d8d0060012f6def6cf559c5291d131

Figured it might make more sense for you to change this than for me to create a separate PR which is mostly your changes.

@luisobo when do you think you would have a chance to review + merge this PR?

stephengazzard avatar Oct 26 '16 18:10 stephengazzard

I'd be happy to merge this, but I would like to get the travis build passing first.

Travis - OS X CI environment Travis - testing on multiple OSs

I'm assuming if we get it running in travis on osx_image: xcode8 things should be good. We need to add a matrix section first though. We probably want to add a matrix of OSs to run/build/test on, and since we are building for multiple platforms now, probably need to add scripts to run on the various sdks (the last part is outside the scope for this PR though)

andrewkboyd avatar Oct 26 '16 19:10 andrewkboyd

I had just a few minutes to play around with this today and made some changes to the travis.yml file on a separate branch with your changes.

I got it working, but need to think about how to ensure that things still work across the various platforms.

andrewkboyd avatar Feb 02 '17 19:02 andrewkboyd

Is this still under development?

tpalmer avatar Aug 20 '18 14:08 tpalmer