Skip to content

Commit

Permalink
Bump versions to 0.15.0 (#166)
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewchang-bird authored Aug 13, 2020
1 parent d3214ab commit 50feb5e
Show file tree
Hide file tree
Showing 87 changed files with 10,581 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import PackageDescription
let package = Package(
name: "Mockingbird",
platforms: [
.macOS(.v10_14),
.macOS(.v10_10),
.iOS(.v8),
.tvOS(.v9),
],
Expand Down
8 changes: 5 additions & 3 deletions README-0.15.md → README-0.16.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ Add the framework to a test target in your `Podfile`, making sure to include the
```ruby
target 'MyAppTests' do
use_frameworks!
pod 'MockingbirdFramework', '~> 0.14'
pod 'MockingbirdFramework', '~> 0.15'
end
```

Expand Down Expand Up @@ -116,7 +116,7 @@ Have questions or issues?
Add the framework to your `Cartfile`.

```
github "birdrides/mockingbird" ~> 0.14
github "birdrides/mockingbird" ~> 0.15
```

Build the framework with Carthage, [link it to your test target](https://github.com/birdrides/mockingbird/wiki/Linking-Test-Targets), and install the CLI.
Expand Down Expand Up @@ -152,11 +152,13 @@ Add the framework as a package dependency and link it to your test target.

<details><summary>Click here if you are using a <code>Package.swift</code> manifest file instead.</summary>

Add `.package(name: "Mockingbird", …)` and declare `"Mockingbird"` as a dependency of your `.testTarget`.

```swift
let package = Package(
name: "MyPackage",
dependencies: [
.package(url: "https://github.com/birdrides/mockingbird.git", .upToNextMinor(from: "0.14.0")),
.package(name: "Mockingbird", url: "https://github.com/birdrides/mockingbird.git", .upToNextMinor(from: "0.15.0")),
],
targets: [
.testTarget(name: "MyPackageTests", dependencies: ["Mockingbird"]),
Expand Down
10 changes: 7 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ Add the framework to a test target in your `Podfile`, making sure to include the
```ruby
target 'MyAppTests' do
use_frameworks!
pod 'MockingbirdFramework', '~> 0.14'
pod 'MockingbirdFramework', '~> 0.15'
end
```

Expand Down Expand Up @@ -116,7 +116,7 @@ Have questions or issues?
Add the framework to your `Cartfile`.

```
github "birdrides/mockingbird" ~> 0.14
github "birdrides/mockingbird" ~> 0.15
```

Build the framework with Carthage, [link it to your test target](https://github.com/birdrides/mockingbird/wiki/Linking-Test-Targets), and install the CLI.
Expand Down Expand Up @@ -152,11 +152,13 @@ Add the framework as a package dependency and link it to your test target.

<details><summary>Click here if you are using a <code>Package.swift</code> manifest file instead.</summary>

Add `.package(name: "Mockingbird", …)` and declare `"Mockingbird"` as a dependency of your `.testTarget`.

```swift
let package = Package(
name: "MyPackage",
dependencies: [
.package(url: "https://github.com/birdrides/mockingbird.git", .upToNextMinor(from: "0.14.0")),
.package(name: "Mockingbird", url: "https://github.com/birdrides/mockingbird.git", .upToNextMinor(from: "0.15.0")),
],
targets: [
.testTarget(name: "MyPackageTests", dependencies: ["Mockingbird"]),
Expand Down Expand Up @@ -573,6 +575,7 @@ Generate mocks for a set of targets in a project.
| `--srcroot` | `$SRCROOT` | The folder containing your project’s source files. |
| `--outputs` | [`(inferred)`](#--outputs) | List of mock output file paths for each target. |
| `--support` | [`(inferred)`](#--support) | The folder containing [supporting source files](https://github.com/birdrides/mockingbird/wiki/Supporting-Source-Files). |
| `--header` | `(none)` | Content to add at the beginning of each generated mock file. |
| `--condition` | `(none)` | [Compilation condition](https://docs.swift.org/swift-book/ReferenceManual/Statements.html#ID538) to wrap all generated mocks in, e.g. `DEBUG`. |
| `--diagnostics` | `(none)` | List of [diagnostic generator warnings](https://github.com/birdrides/mockingbird/wiki/Diagnostic-Warnings-and-Errors) to enable. |

Expand All @@ -599,6 +602,7 @@ Configure a test target to use mocks.
| `--srcroot` | `<project>/../` | The folder containing your project’s source files. |
| `--outputs` | [`(inferred)`](#--outputs) | List of mock output file paths for each target. |
| `--support` | [`(inferred)`](#--support) | The folder containing [supporting source files](https://github.com/birdrides/mockingbird/wiki/Supporting-Source-Files). |
| `--header` | `(none)` | Content to add at the beginning of each generated mock file. |
| `--condition` | `(none)` | [Compilation condition](https://docs.swift.org/swift-book/ReferenceManual/Statements.html#ID538) to wrap all generated mocks in, e.g. `DEBUG`. |
| `--diagnostics` | `(none)` | List of [diagnostic generator warnings](https://github.com/birdrides/mockingbird/wiki/Diagnostic-Warnings-and-Errors) to enable. |
| `--loglevel` | `(none)` | The log level to use when generating mocks, `quiet` or `verbose`. |
Expand Down
2 changes: 1 addition & 1 deletion Sources/MockingbirdCli/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.14.0</string>
<string>0.15.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
</dict>
Expand Down
2 changes: 1 addition & 1 deletion Sources/MockingbirdFramework/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.14.0</string>
<string>0.15.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
</dict>
Expand Down
2 changes: 1 addition & 1 deletion Sources/MockingbirdFramework/Utilities/Version.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import Foundation

/// Swift Package Manager doesn't create an Info.plist section in the binary like xcodebuild.
let mockingbirdVersion = Version(shortString: "0.14.0")
let mockingbirdVersion = Version(shortString: "0.15.0")

struct Version: Comparable, CustomStringConvertible {
let semver: [Int]
Expand Down
2 changes: 1 addition & 1 deletion Sources/MockingbirdGenerator/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.14.0</string>
<string>0.15.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
Expand Down
2 changes: 1 addition & 1 deletion Sources/MockingbirdGenerator/Utilities/Version.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import Foundation

/// Swift Package Manager doesn't create an Info.plist section in the binary like xcodebuild.
public let mockingbirdVersion = Version(shortString: "0.14.0")
public let mockingbirdVersion = Version(shortString: "0.15.0")

public struct Version: Comparable, CustomStringConvertible {
let semver: [Int]
Expand Down
181 changes: 181 additions & 0 deletions docs/0.15.0/ArgumentCaptor-1017688/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,181 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Mockingbird - ArgumentCaptor</title>
<link rel="stylesheet" type="text/css" href="/mockingbird/0.15.0/all.css" media="all" />
</head>
<body>
<header>
<a href="/mockingbird/0.15.0">
<strong>
Mockingbird
</strong>
<span>Documentation</span>
</a>
<sup>0.15.0</sup>
</header>

<!--
<form class="search">
<input type="search" placeholder="Search" />
</form>
-->

<nav>
<div class="wrapper">
<h2>On This Page</h2>
<ol><li><a href="#relationships">Relationships</a><ul><li><a href="#relationships">Superclass</a></li></ul></li><li><a href="#initializers">Initializers</a><ul><li class="initializer"><a href="#argumentcaptor.init(weak:)">init(weak:​)</a></li></ul></li><li><a href="#properties">Properties</a><ul><li class="property"><a href="#argumentcaptor.matcher">matcher</a></li><li class="property"><a href="#argumentcaptor.allvalues">all​Values</a></li><li class="property"><a href="#argumentcaptor.value">value</a></li></ul></li></ol>
</div>
</nav>

<main>
<article>
<h1>
<small>Class</small>
<code class="name">Argument​Captor</code>
</h1>

<html><body><pre class="highlight"><code><span class="keyword">public</span> <span class="keyword">class</span> <span class="type">ArgumentCaptor</span>&lt;<span class="variable">ParameterType</span>&gt;: <a href="/mockingbird/0.15.0/ArgumentMatcher-f013d1a"><span class="type">ArgumentMatcher</span></a></code></pre></body></html>
<div class="summary" role="doc-abstract">
<p>Captures method arguments passed during mock invocations.</p>

</div>
<div class="discussion">
<p>An argument captor extracts received argument values which can be used in other parts of the
test.</p>

<html><body><pre class="highlight"><code><span class="keyword">let</span> <span class="variable">bird</span> = <span class="variable">mock</span>(<span class="variable">Bird</span>.<span class="keyword">self</span>)
<span class="variable">bird</span>.<span class="type">name</span> = <span class="string literal">"</span><span class="string literal">Ryan</span><span class="string literal">"</span>

<span class="keyword">let</span> <span class="variable">nameCaptor</span> = <span class="variable">ArgumentCaptor</span>&lt;<span class="type">String</span>&gt;()
<span class="variable">verify</span>(<span class="variable">bird</span>.<span class="type">setName</span>(<span class="variable">nameCaptor</span>.<span class="type">matcher</span>)).<span class="type">wasCalled</span>()
<span class="variable">print</span>(<span class="variable">nameCaptor</span>.<span class="type">value</span>) <span class="comment">// Prints "Ryan"</span>
</code></pre></body></html>
</div>
<section id="relationships">
<h2 hidden>Relationships</h2>
<figure>
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 2.36.0 (20140111.2315)
-->
<!-- Title: %3 Pages: 1 -->
<svg width="872pt" height="116pt"
viewBox="0.00 0.00 872.00 116.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 112)">
<title>%3</title>
<polygon fill="white" stroke="none" points="-4,4 -4,-112 868,-112 868,4 -4,4"/>
<!-- ArgumentCaptor -->
<g id="node1" class="node"><title>ArgumentCaptor</title>
<g id="a_node1"><a xlink:href="/mockingbird/0.15.0/ArgumentCaptor-1017688" xlink:title="ArgumentCaptor">
<path fill="none" stroke="black" stroke-width="3" d="M528,-108C528,-108 336,-108 336,-108 330,-108 324,-102 324,-96 324,-96 324,-84 324,-84 324,-78 330,-72 336,-72 336,-72 528,-72 528,-72 534,-72 540,-78 540,-84 540,-84 540,-96 540,-96 540,-102 534,-108 528,-108"/>
<text text-anchor="middle" x="432" y="-86.9484" font-family="Menlo" font-size="14.00">ArgumentCaptor</text>
</a>
</g>
</g>
<!-- ArgumentMatcher -->
<g id="node2" class="node"><title>ArgumentMatcher</title>
<path fill="none" stroke="black" d="M528,-36C528,-36 336,-36 336,-36 330,-36 324,-30 324,-24 324,-24 324,-12 324,-12 324,-6 330,-0 336,-0 336,-0 528,-0 528,-0 534,-0 540,-6 540,-12 540,-12 540,-24 540,-24 540,-30 534,-36 528,-36"/>
<text text-anchor="middle" x="432" y="-14.9484" font-family="Menlo" font-size="14.00">ArgumentMatcher</text>
</g>
<!-- ArgumentCaptor&#45;&gt;ArgumentMatcher -->
<g id="edge1" class="edge"><title>ArgumentCaptor&#45;&gt;ArgumentMatcher</title>
<path fill="none" stroke="black" d="M432,-71.6966C432,-63.9827 432,-54.7125 432,-46.1124"/>
<polygon fill="black" stroke="black" points="435.5,-46.1043 432,-36.1043 428.5,-46.1044 435.5,-46.1043"/>
</g>
</g>
</svg>


<figcaption hidden>Inheritance graph for ArgumentCaptor.</figcaption>
</figure>
<h3>Superclass</h3>
<dl>
<dt class="class"><code><a href="/mockingbird/0.15.0/ArgumentMatcher-f013d1a">ArgumentMatcher</a></code></dt>
<dd><p>Matches argument values with a comparator.</p>
</dd>
</dl>
</section>
<section id="initializers">
<h2>Initializers</h2>

<div role="article" class="initializer" id="argumentcaptor.init(weak:)">
<h3>
<code>init(weak:​)</code>
</h3>
<html><body><pre class="highlight"><code><span class="keyword">public</span> <span class="keyword">init</span>(<span class="variable">weak</span>: <span class="type">Bool</span> = <span class="keyword">false</span>)</code></pre></body></html>
<div class="summary" role="doc-abstract">
<p>Create a new argument captor.</p>

</div>
<h4>Parameters</h4>

<table class="parameters">
<thead hidden>
<tr>
<th>Name</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<th>weak</th>
<td><code class="type">Bool</code></td></td>
<td><p>Whether captured arguments should be stored weakly.</p>
</td>
</tr>
</tbody>
</table>
</div>
</section>
<section id="properties">
<h2>Properties</h2>

<div role="article" class="variable" id="argumentcaptor.matcher">
<h3>
<code>matcher</code>
</h3>
<html><body><pre class="highlight"><code><span class="keyword">var</span> <span class="variable">matcher</span>: <span class="type">ParameterType</span></code></pre></body></html>
<div class="summary" role="doc-abstract">
<p>Passed as a parameter to mock verification contexts.</p>

</div>
</div>
<div role="article" class="variable" id="argumentcaptor.allvalues">
<h3>
<code>all​Values</code>
</h3>
<html><body><pre class="highlight"><code><span class="keyword">var</span> <span class="variable">allValues</span>: [<span class="type">ParameterType</span>]</code></pre></body></html>
<div class="summary" role="doc-abstract">
<p>All recorded argument values.</p>

</div>
</div>
<div role="article" class="variable" id="argumentcaptor.value">
<h3>
<code>value</code>
</h3>
<html><body><pre class="highlight"><code><span class="keyword">var</span> <span class="variable">value</span>: <span class="type">ParameterType</span>?</code></pre></body></html>
<div class="summary" role="doc-abstract">
<p>The last recorded argument value.</p>

</div>
</div>
</section>



</article>
</main>

<footer>
<p>
Generated on <time datetime="2020-08-12T14:19:42-0700">August 12, 2020</time> using <a href="https://github.com/SwiftDocOrg/swift-doc">swift-doc</a> <span class="version">1.0.0-beta.3</span>.
</p>
</footer>
</body>
</html>
Loading

0 comments on commit 50feb5e

Please sign in to comment.