mirror of https://github.com/SnapKit/SnapKit
Merge pull request #228 from vittoriom/osx/fixTestsAndEnableTravis
Fixes tests not compiling on the OS X target and adds a line for the travis.yml so that tests are always ran
This commit is contained in:
commit
1770df617b
|
@ -10,6 +10,6 @@ before_install:
|
|||
- gem install xcpretty -N
|
||||
script:
|
||||
- set -o pipefail
|
||||
- xcodebuild -project SnapKit.xcodeproj -scheme "SnapKit iOS" -sdk iphonesimulator
|
||||
-destination "platform=iOS Simulator,name=iPhone 6" ONLY_ACTIVE_ARCH=NO test | xcpretty -c
|
||||
- xcodebuild -project SnapKit.xcodeproj -scheme "SnapKit iOS" -sdk iphonesimulator -destination "platform=iOS Simulator,name=iPhone 6" ONLY_ACTIVE_ARCH=NO test | xcpretty -c
|
||||
- xcodebuild -project SnapKit.xcodeproj -scheme "SnapKit OSX" ONLY_ACTIVE_ARCH=YES test | xcpretty -c
|
||||
- pod lib lint --quick
|
||||
|
|
|
@ -282,11 +282,11 @@ class SnapKitTests: XCTestCase {
|
|||
XCTAssertEqual(constraints[0].secondAttribute, NSLayoutAttribute.Top, "Should be top")
|
||||
XCTAssertEqual(constraints[1].secondAttribute, NSLayoutAttribute.Bottom, "Should be bottom")
|
||||
|
||||
XCTAssertEqual(constraints[0].firstItem as? UIView, view, "Should be added subview")
|
||||
XCTAssertEqual(constraints[1].firstItem as? UIView, view, "Should be added subview")
|
||||
XCTAssertEqual(constraints[0].firstItem as? View, view, "Should be added subview")
|
||||
XCTAssertEqual(constraints[1].firstItem as? View, view, "Should be added subview")
|
||||
|
||||
XCTAssertEqual(constraints[0].secondItem as? UIView, container, "Should be containerView")
|
||||
XCTAssertEqual(constraints[1].secondItem as? UIView, container, "Should be containerView")
|
||||
XCTAssertEqual(constraints[0].secondItem as? View, container, "Should be containerView")
|
||||
XCTAssertEqual(constraints[1].secondItem as? View, container, "Should be containerView")
|
||||
|
||||
XCTAssertEqual(constraints[0].constant, 10, "Should be 10")
|
||||
XCTAssertEqual(constraints[1].constant, -10, "Should be 10")
|
||||
|
|
Loading…
Reference in New Issue