JohnSundell / SwiftPlate

Easily generate cross platform Swift framework projects from the command line
MIT License
1.77k stars 88 forks source link

Optional support for Quick + Nimble testing via Cocoapods #58

Open KieranHarper opened 7 years ago

KieranHarper commented 7 years ago

Couple of things here:

  1. Added an optional folder for storing things that aren't part of the copy-paste template unless you opt into them via the prompts.
  2. Added a prompt about using Cocoapods in general - provides a file ready for dependencies to be added and initialises the workspace.
  3. Added a prompt about using Quick and Nimble via Cocoapods - uses an alternative starting podfile.
  4. Added those dependencies to the package manager file if you opt into Q+N.

That last point creates a slight problem if you want to test via swift test you'll end up having those dependencies included when you swift build as well, which isn't ideal. It's a known issue for SPM that's being worked on (I'm not completely across the status tho). I've included it here by default because it means this can hit all platforms, but people can also delete it if they're happy to just test through Xcode. If you merge this PR I'll create an issue to track that.

kiliankoe commented 6 years ago

FYI, Swift 4's SPM now supports test dependencies 😊