Merge pull request #48 from Kuniwak/cocoapods Fix CocoaPods issues
Merge pull request #48 from Kuniwak/cocoapods
Fix CocoaPods issues
A tool for providing the 2 features for efficient testing:
diff<T>(between: T, and: T)
import MirrorDiffKit // Input 2 structs or classes implements Equatable: let a = Example( key1: "I'm not changed", key2: "I'm deleted" ) let b = Example( key1: "I'm not changed", key2: "I'm inserted" ) XCTAssertEqual(a, b, diff(between: a, and: b)) // XCTAssertEqual failed: ("Example(key1: "I``` ### `Any =~ Any` and `Any !~ Any` ```swift import MirrorDiffKit a = NotEquatable( key1: "I'm not changed", key2: "I'm deleted" ) b = NotEquatable( key1: "I'm not changed", key2: "I'm inserted" ) XCTAssert(a =~ b, diff(between: a, and: b)) // XCTAssertTrue failed - // struct NotEquatable { // key1: "I'm not changed" // - key2: "I'm deleted" // + key2: "I'm inserted" // }
Add the following line to your Package.swift:
Package.swift
.package(url: "https://github.com/Kuniwak/MirrorDiffKit.git")
Add the following line to your Cartfile:
Cartfile
github "Kuniwak/MirrorDiffKit"
pod "MirrorDiffKit"
m not changed”, key2: “I```
Any =~ Any
Any !~ Any
import MirrorDiffKit a = NotEquatable( key1: "I'm not changed", key2: "I'm deleted" ) b = NotEquatable( key1: "I'm not changed", key2: "I'm inserted" ) XCTAssert(a =~ b, diff(between: a, and: b)) // XCTAssertTrue failed - // struct NotEquatable { // key1: "I'm not changed" // - key2: "I'm deleted" // + key2: "I'm inserted" // }
m deleted”)”) is not equal to (“Example(key1: “I```
m inserted”)”) - // struct Example { // key1: “I’m not changed” // - key2: “I’m deleted” // + key2: “I’m inserted” // }
### `Any =~ Any` and `Any !~ Any` ```swift import MirrorDiffKit a = NotEquatable( key1: "I'm not changed", key2: "I'm deleted" ) b = NotEquatable( key1: "I'm not changed", key2: "I'm inserted" ) XCTAssert(a =~ b, diff(between: a, and: b)) // XCTAssertTrue failed - // struct NotEquatable { // key1: "I'm not changed" // - key2: "I'm deleted" // + key2: "I'm inserted" // }
©Copyright 2023 CCF 开源发展委员会 Powered by Trustie& IntelliDE 京ICP备13000930号
A tool for providing the 2 features for efficient testing:
Usage
diff<T>(between: T, and: T)
Installation
Swift Package Manager
Add the following line to your
Package.swift
:Carthage
Add the following line to your
Cartfile
:CocoaPods
m not changed”, key2: “I```
Any =~ Any
andAny !~ Any
Installation
Swift Package Manager
Add the following line to your
Package.swift
:Carthage
Add the following line to your
Cartfile
:CocoaPods
m deleted”)”) is not equal to (“Example(key1: “I```
Any =~ Any
andAny !~ Any
Installation
Swift Package Manager
Add the following line to your
Package.swift
:Carthage
Add the following line to your
Cartfile
:CocoaPods
m not changed”, key2: “I```
Any =~ Any
andAny !~ Any
Installation
Swift Package Manager
Add the following line to your
Package.swift
:Carthage
Add the following line to your
Cartfile
:CocoaPods
m inserted”)”) - // struct Example { // key1: “I’m not changed” // - key2: “I’m deleted” // + key2: “I’m inserted” // }
Installation
Swift Package Manager
Add the following line to your
Package.swift
:Carthage
Add the following line to your
Cartfile
:CocoaPods