Conversation
Since we can't use a bundle to find the test data, we fall back on a relative path from the built executable. This is a bit skanky, but it's a useable workaround.
… some tests for it. Hooked up some missing tests for Linux.
|
That looks great, massive thanks for the effort! One thing I'm concerned about is Objective-C support, which this PR is dropping in favor of Linux. I'll think about it and get back to you. Another thing - if we decide that Linux is the way to go, then travis ci should also run tests on Linux. Do you think they support swift on Linux by now? |
Ah, hmm - I wasn't specifically intending to drop Obj-C support, but of course I did. Is there an existing Obj-C port of Docopt? I suppose I'd say that if people are working in a mixed environment they should use that (if it exists), and that this one should aim to be a pure-Swift one. I can see though that it's hard to please everyone :)
Funnily enough I'm in the process of figuring this out at the moment for one of my other packages. It looks like it works with a bit of tweaking. I'll update #14 when I've got it going. |
# Conflicts: # Sources/Docopt/Docopt.swift
|
Unfortunately, I don't know any obj-c compatible ports of docopt. On the other hand, I think it would be fair to say that version 0.6.6 is the last that supports objective-c. And obj-c compatible version will still be available to download and use. Again, thanks a lot for the effort, I really appreciate it! |
Not quite sure what's going on here - I thought I was testing with Swift 4.1 on both platforms, but it appears not...
|
@samdeane tests on Linux are failing even tough travis reports a success. |
|
Hmm. Looks like the final run did pass, although there are some warnings. I'll see if I can stomp them. There seems to be a subtle difference between the Mac and Linux compilers that I'm testing with, probably because the Linux one is a development snapshot. |
|
Perhaps this project needs to be split, having the ObjC one in another repo? |
NB This is work in progress. It incorporates the changes from #12 and #13 so it would make sense to review/merge them first. I've changed the project layout slightly so the Cocoapods file may need tweaking.
Changes to build on Linux:
@objcAnyObject, in favour of just usingAnyNSObjectNSObject/NSValue/etcLinuxMain.swiftfor tests and hooked it up to the existing tests