Comments (4)
Once #6 is resolved this should be put to bed.
from quick.
Here's what I've tried so far:
1. CocoaPods and Quick.podspec
No dice: CocoaPods doesn't support mix & matched code. To be more precise, it's impossible to import the "Quick-Swift.h" header in QuickSpec
, since the Quick module is not built. To CocoaPods, Quick is just a set of source files in a folder in the Pods project of the workspace. We may be able to import "Pods-Swift.h", but I doubt it.
2. Two targets: one iOS static library and one OS X static library
No dice: static libraries are created using libtool, which doesn't understand the flags needed when building Swift code. The following error occurs:
Libtool /Users/MBP-006FYGC/Library/Developer/Xcode/DerivedData/Quick-chbdhbmwzcgjlyfsbxuvmajagydy/Build/Products/Debug/libQuick-OSX.a normal x86_64
cd /Users/MBP-006FYGC/GitHub/modocache/Quick
export MACOSX_DEPLOYMENT_TARGET=10.7
/Applications/Xcode6-Beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -static -arch_only x86_64 -syslibroot /Applications/Xcode6-Beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -L/Users/MBP-006FYGC/Library/Developer/Xcode/DerivedData/Quick-chbdhbmwzcgjlyfsbxuvmajagydy/Build/Products/Debug -filelist /Users/MBP-006FYGC/Library/Developer/Xcode/DerivedData/Quick-chbdhbmwzcgjlyfsbxuvmajagydy/Build/Intermediates/Quick.build/Debug/Quick-OSX.build/Objects-normal/x86_64/Quick-OSX.LinkFileList -ObjC -L/Applications/Xcode6-Beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx -Xlinker -rpath -Xlinker /Applications/Xcode6-Beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx -Xlinker -force_load -Xlinker /Applications/Xcode6-Beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_macosx.a -Xlinker -sectalign -Xlinker __SWIFT -Xlinker __ast -Xlinker 4 -Xlinker -sectcreate -Xlinker __SWIFT -Xlinker __ast -Xlinker /Users/MBP-006FYGC/Library/Developer/Xcode/DerivedData/Quick-chbdhbmwzcgjlyfsbxuvmajagydy/Build/Intermediates/Quick.build/Debug/Quick-OSX.build/Objects-normal/x86_64/Quick_OSX.swiftmodule -framework XCTest -framework Foundation -o /Users/MBP-006FYGC/Library/Developer/Xcode/DerivedData/Quick-chbdhbmwzcgjlyfsbxuvmajagydy/Build/Products/Debug/libQuick-OSX.a
error: /Applications/Xcode6-Beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool: unknown option character `X' in: -Xlinker
Usage: /Applications/Xcode6-Beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -static [-] file [...] [-filelist listfile[,dirname]] [-arch_only arch] [-sacLT] [-no_warning_for_no_symbols]
Usage: /Applications/Xcode6-Beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -dynamic [-] file [...] [-filelist listfile[,dirname]] [-arch_only arch] [-o output] [-install_name name] [-compatibility_version #] [-current_version #] [-seg1addr 0x#] [-segs_read_only_addr 0x#] [-segs_read_write_addr 0x#] [-seg_addr_table <filename>] [-seg_addr_table_filename <file_system_path>] [-all_load] [-noall_load]
3. Two targets: one iOS framework and one OS X framework
This might work, but you can't link XCTest against an iOS framework. I can't get the iOS framework to build.
from quick.
It seems a little extreme that merely adding a Swift file to a static library target produces such a cryptic error message, so I filed a radar: http://openradar.appspot.com/radar?id=5536341827780608
from quick.
@sharplet, you're a genius.
from quick.
Related Issues (20)
- Testing with `Behavior<Context>` does not seem to support Swift concurrency HOT 2
- `@MainActor` for QuickSpec subclass doesn't work when installing Quick via SPM HOT 4
- Failed to build module 'Quick'; this SDK is not supported by the compiler HOT 1
- Would it be possible to hide the new/old test naming behind a feature flag? HOT 3
- Realm does not work with Async Specs HOT 8
- Allow async `xit` HOT 1
- Integrate individual platform targets into a single Multiplatform target.
- No Objective C support in SwiftPM
- AsyncSpecs not run in bulk on Quick 7 (but run individuately) HOT 6
- Make `xitBehavesLike` with a `String` as a name publicly available (sync and async) HOT 1
- Is this framework support SwiftUI Unit / UI testing ? HOT 1
- Mutation of captured var 'ocean' in concurrently-executing code HOT 1
- Framework in the release assets doesn't work on Apple Silicon Macs. HOT 6
- `configure(_:)` on a `QuickConfiguration` subclass is not called when you do not have any `QuickSpec`s or `AsyncSpec`s.
- Add visionOS support HOT 3
- Instance member '' cannot be used on type ''
- 'afterEach' cannot be used inside 'it', 'afterEach' may only be used inside 'context' or 'describe' HOT 2
- When testing a class with `@MainActor` annotation the `QuickSpec` doesn't work HOT 1
- Privacy Manifest
- Sometimes TestState crashes for AsyncSpec HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from quick.