diff --git a/data/documentation/nimble.json b/data/documentation/nimble.json index 81cfef5c9..e279d4193 100644 --- a/data/documentation/nimble.json +++ b/data/documentation/nimble.json @@ -50,7 +50,7 @@ { "inlineContent" : [ { - "text" : "Nimbel provides 3 things:", + "text" : "Nimble provides 4 things:", "type" : "text" } ], @@ -85,7 +85,7 @@ "type" : "strong" }, { - "text" : ", or functions to check the outcome of an expression.", + "text" : ", or functions to check the Behavior of an expression.", "type" : "text" } ], @@ -111,7 +111,7 @@ "type" : "strong" }, { - "text" : " - an expression-matcher combination to pass before continuing.", + "text" : " - an expression-matcher combination - to pass before continuing.", "type" : "text" } ], @@ -134,6 +134,219 @@ } ], "type" : "unorderedList" + }, + { + "anchor" : "Terms", + "level" : 2, + "text" : "Terms", + "type" : "heading" + }, + { + "items" : [ + { + "definition" : { + "content" : [ + { + "inlineContent" : [ + { + "text" : "A Swift or Objective-C bit of code. For example ", + "type" : "text" + }, + { + "code" : "1 + 1", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + "term" : { + "inlineContent" : [ + { + "text" : "Expression", + "type" : "text" + } + ] + } + }, + { + "definition" : { + "content" : [ + { + "inlineContent" : [ + { + "text" : "A result or side effect of an expression. For example ", + "type" : "text" + }, + { + "code" : "print(\"hello\")", + "type" : "codeVoice" + }, + { + "text" : " has a behavior of writing “hello\\n” to standard output, while ", + "type" : "text" + }, + { + "code" : "1 + 1", + "type" : "codeVoice" + }, + { + "text" : " has a behavior of returning 2.", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + "term" : { + "inlineContent" : [ + { + "text" : "Behavior", + "type" : "text" + } + ] + } + }, + { + "definition" : { + "content" : [ + { + "inlineContent" : [ + { + "text" : "A function from Nimble which checks an Expression’s Behavior.", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + "term" : { + "inlineContent" : [ + { + "text" : "Matcher", + "type" : "text" + } + ] + } + }, + { + "definition" : { + "content" : [ + { + "inlineContent" : [ + { + "text" : "An Expression combined with an Expression. For example, ", + "type" : "text" + }, + { + "code" : "expect(1 + 1).to(equal(2))", + "type" : "codeVoice" + }, + { + "text" : " is an Expectation.", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + "term" : { + "inlineContent" : [ + { + "text" : "Expectation", + "type" : "text" + } + ] + } + }, + { + "definition" : { + "content" : [ + { + "inlineContent" : [ + { + "text" : "An expectation that is continuously polled until it finishes.", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + "term" : { + "inlineContent" : [ + { + "text" : "Polling Expectation", + "type" : "text" + } + ] + } + }, + { + "definition" : { + "content" : [ + { + "inlineContent" : [ + { + "text" : "An Expectation that must pass before continuing. These are usually defined using ", + "type" : "text" + }, + { + "code" : "require", + "type" : "codeVoice" + }, + { + "text" : " instead of ", + "type" : "text" + }, + { + "code" : "expect", + "type" : "codeVoice" + }, + { + "text" : ", though there are shortcuts such as ", + "type" : "text" + }, + { + "code" : "unwrap(file:line:customError:_:)-5q9f3", + "type" : "codeVoice" + }, + { + "text" : " and ", + "type" : "text" + }, + { + "code" : "pollUnwrap(file:line:_:)-4ddnp", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + "term" : { + "inlineContent" : [ + { + "text" : "Requirement", + "type" : "text" + } + ] + } + } + ], + "type" : "termList" } ], "kind" : "content" @@ -181,13 +394,17 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" }, + { + "generated" : true, + "identifiers" : [ + "doc:\/\/Nimble\/documentation\/Nimble\/Collections" + ], + "title" : "Articles" + }, { "identifiers" : [ "doc:\/\/Nimble\/documentation\/Nimble\/AssertionDispatcher", @@ -10132,45 +10349,34 @@ "type" : "topic", "url" : "\/documentation\/nimble\/badinstructionexception" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Collections": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Nimble allows you to easily check ", + "type" : "text" + }, + { + "code" : "Collection", + "type" : "codeVoice" + }, + { + "text" : "s.", "type" : "text" } ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Collections", "kind" : "article", "role" : "article", - "title" : "Collection Membership", + "title" : "Collection", "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" + "url" : "\/documentation\/nimble\/collections" }, "doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ - + { + "text" : "Comparing the expression with other values.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -10195,7 +10401,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -10240,7 +10449,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -10251,7 +10463,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -10595,7 +10810,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -10606,7 +10824,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -10618,39 +10839,7 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "are equal to something else. For this, use the ", - "type" : "text" - }, - { - "code" : "map", - "type" : "codeVoice" - }, - { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" } ], @@ -11143,7 +11332,30 @@ }, "doc://Nimble/documentation/Nimble/Notifications": { "abstract" : [ - + { + "text" : "Checking Notifications posted to ", + "type" : "text" + }, + { + "code" : "NotificationCenter", + "type" : "codeVoice" + }, + { + "text" : " or a", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "DistributedNotificationCenter", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -11486,7 +11698,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -11528,7 +11771,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -11559,33 +11853,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -11603,11 +11887,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -11758,7 +12056,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -30055,30 +30356,6 @@ "title" : "withAssertionHandler(_:file:line:closure:)", "type" : "topic", "url" : "\/documentation\/nimble\/withassertionhandler(_:file:line:closure:)-n9cw" -}, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ - { - "text" : "@mattgallagher", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" -}, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ - { - "text" : "CwlPreconditionTesting", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" } } } \ No newline at end of file diff --git a/data/documentation/nimble/collectioncount.json b/data/documentation/nimble/collectioncount.json deleted file mode 100644 index 024a451cd..000000000 --- a/data/documentation/nimble/collectioncount.json +++ /dev/null @@ -1,561 +0,0 @@ -{ - "hierarchy" : { - "paths" : [ - [ - "doc:\/\/Nimble\/documentation\/Nimble" - ] - ] - }, - "identifier" : { - "interfaceLanguage" : "swift", - "url" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" - }, - "kind" : "article", - "metadata" : { - "modules" : [ - { - "name" : "Nimble" - } - ], - "role" : "article", - "roleHeading" : "Article", - "title" : "Collection Count" - }, - "primaryContentSections" : [ - { - "content" : [ - { - "anchor" : "overview", - "level" : 2, - "text" : "Overview", - "type" : "heading" - }, - { - "code" : [ - "\/\/ Swift", - "", - "\/\/ Passes if 'actual' contains the 'expected' number of elements:", - "expect(actual).to(haveCount(expected))", - "", - "\/\/ Passes if 'actual' does _not_ contain the 'expected' number of elements:", - "expect(actual).notTo(haveCount(expected))" - ], - "syntax" : "swift", - "type" : "codeListing" - }, - { - "code" : [ - "\/\/ Objective-C", - "", - "\/\/ Passes if 'actual' contains the 'expected' number of elements:", - "expect(actual).to(haveCount(expected))", - "", - "\/\/ Passes if 'actual' does _not_ contain the 'expected' number of elements:", - "expect(actual).notTo(haveCount(expected))" - ], - "syntax" : "objc", - "type" : "codeListing" - }, - { - "inlineContent" : [ - { - "text" : "For Swift, the actual value must be an instance of a type conforming to ", - "type" : "text" - }, - { - "code" : "Collection", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "For example, instances of ", - "type" : "text" - }, - { - "code" : "Array", - "type" : "codeVoice" - }, - { - "text" : ", ", - "type" : "text" - }, - { - "code" : "Dictionary", - "type" : "codeVoice" - }, - { - "text" : ", or ", - "type" : "text" - }, - { - "code" : "Set", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "inlineContent" : [ - { - "text" : "For Objective-C, the actual value must be one of the following classes, or their subclasses:", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "items" : [ - { - "content" : [ - { - "inlineContent" : [ - { - "code" : "NSArray", - "type" : "codeVoice" - }, - { - "text" : ",", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - }, - { - "content" : [ - { - "inlineContent" : [ - { - "code" : "NSDictionary", - "type" : "codeVoice" - }, - { - "text" : ",", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - }, - { - "content" : [ - { - "inlineContent" : [ - { - "code" : "NSSet", - "type" : "codeVoice" - }, - { - "text" : ", or", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - }, - { - "content" : [ - { - "inlineContent" : [ - { - "code" : "NSHashTable", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - } - ], - "type" : "unorderedList" - } - ], - "kind" : "content" - } - ], - "schemaVersion" : { - "major" : 0, - "minor" : 3, - "patch" : 0 - }, - "sections" : [ - - ], - "seeAlsoSections" : [ - { - "generated" : true, - "identifiers" : [ - "doc:\/\/Nimble\/documentation\/Nimble\/TypeChecking", - "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", - "doc:\/\/Nimble\/documentation\/Nimble\/Identity", - "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", - "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", - "doc:\/\/Nimble\/documentation\/Nimble\/SwiftAssertions", - "doc:\/\/Nimble\/documentation\/Nimble\/SwiftErrors", - "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", - "doc:\/\/Nimble\/documentation\/Nimble\/Strings", - "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", - "doc:\/\/Nimble\/documentation\/Nimble\/Result", - "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", - "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements" - ], - "title" : "Matchers" - } - ], - "variants" : [ - { - "paths" : [ - "\/documentation\/nimble\/collectioncount" - ], - "traits" : [ - { - "interfaceLanguage" : "swift" - } - ] - } - ] -, -"references": { -"doc://Nimble/documentation/Nimble": { - "abstract" : [ - { - "inlineContent" : [ - { - "text" : "Nimble", - "type" : "text" - } - ], - "type" : "strong" - }, - { - "text" : " is a testing framework for verifying the outcomes and Swift or Objective-C expressions.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble", - "kind" : "symbol", - "role" : "collection", - "title" : "Nimble", - "type" : "topic", - "url" : "\/documentation\/nimble" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { - "abstract" : [ - { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", - "kind" : "article", - "role" : "article", - "title" : "Comparisons", - "type" : "topic", - "url" : "\/documentation\/nimble\/comparisons" -}, -"doc://Nimble/documentation/Nimble/CustomValidation": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "kind" : "article", - "role" : "article", - "title" : "Custom Validation", - "type" : "topic", - "url" : "\/documentation\/nimble\/customvalidation" -}, -"doc://Nimble/documentation/Nimble/Equivalence": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", - "kind" : "article", - "role" : "article", - "title" : "Equivalence", - "type" : "topic", - "url" : "\/documentation\/nimble\/equivalence" -}, -"doc://Nimble/documentation/Nimble/Exceptions": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", - "kind" : "article", - "role" : "article", - "title" : "Exceptions", - "type" : "topic", - "url" : "\/documentation\/nimble\/exceptions" -}, -"doc://Nimble/documentation/Nimble/GroupsOfMatchers": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", - "kind" : "article", - "role" : "article", - "title" : "Matching a value to any of a group of matchers", - "type" : "topic", - "url" : "\/documentation\/nimble\/groupsofmatchers" -}, -"doc://Nimble/documentation/Nimble/Identity": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", - "kind" : "article", - "role" : "article", - "title" : "Identity", - "type" : "topic", - "url" : "\/documentation\/nimble\/identity" -}, -"doc://Nimble/documentation/Nimble/Map": { - "abstract" : [ - { - "text" : "Sometimes, you only want to match against a property or group of properties.", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "are equal to something else. For this, use the ", - "type" : "text" - }, - { - "code" : "map", - "type" : "codeVoice" - }, - { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", - "kind" : "article", - "role" : "article", - "title" : "Notifications", - "type" : "topic", - "url" : "\/documentation\/nimble\/notifications" -}, -"doc://Nimble/documentation/Nimble/Result": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", - "kind" : "article", - "role" : "article", - "title" : "Result", - "type" : "topic", - "url" : "\/documentation\/nimble\/result" -}, -"doc://Nimble/documentation/Nimble/Strings": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", - "kind" : "article", - "role" : "article", - "title" : "Strings", - "type" : "topic", - "url" : "\/documentation\/nimble\/strings" -}, -"doc://Nimble/documentation/Nimble/SwiftAssertions": { - "abstract" : [ - { - "text" : "If you’re using Swift, you can use the ", - "type" : "text" - }, - { - "code" : "throwAssertion", - "type" : "codeVoice" - }, - { - "text" : " matcher to check if an assertion is thrown (e.g. ", - "type" : "text" - }, - { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", - "type" : "text" - }, - { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", - "type" : "text" - }, - { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" - }, - { - "text" : " library.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/SwiftAssertions", - "kind" : "article", - "role" : "article", - "title" : "Swift Assertions", - "type" : "topic", - "url" : "\/documentation\/nimble\/swiftassertions" -}, -"doc://Nimble/documentation/Nimble/SwiftErrors": { - "abstract" : [ - { - "text" : "You can use the ", - "type" : "text" - }, - { - "code" : "throwError", - "type" : "codeVoice" - }, - { - "text" : " matcher to check if an error is thrown.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/SwiftErrors", - "kind" : "article", - "role" : "article", - "title" : "Swift Error Handling", - "type" : "topic", - "url" : "\/documentation\/nimble\/swifterrors" -}, -"doc://Nimble/documentation/Nimble/Truthiness": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", - "kind" : "article", - "role" : "article", - "title" : "Truthiness", - "type" : "topic", - "url" : "\/documentation\/nimble\/truthiness" -}, -"doc://Nimble/documentation/Nimble/TypeChecking": { - "abstract" : [ - { - "text" : "Nimble supports checking the type membership of any kind of object, whether", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "Objective-C conformant or not.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/TypeChecking", - "kind" : "article", - "role" : "article", - "title" : "Type Checking", - "type" : "topic", - "url" : "\/documentation\/nimble\/typechecking" -}, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ - { - "text" : "@mattgallagher", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" -}, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ - { - "text" : "CwlPreconditionTesting", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" -} -} -} \ No newline at end of file diff --git a/data/documentation/nimble/collectionelements.json b/data/documentation/nimble/collectionelements.json deleted file mode 100644 index e997df06c..000000000 --- a/data/documentation/nimble/collectionelements.json +++ /dev/null @@ -1,552 +0,0 @@ -{ - "abstract" : [ - { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", - "type" : "text" - } - ], - "hierarchy" : { - "paths" : [ - [ - "doc:\/\/Nimble\/documentation\/Nimble" - ] - ] - }, - "identifier" : { - "interfaceLanguage" : "swift", - "url" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements" - }, - "kind" : "article", - "metadata" : { - "modules" : [ - { - "name" : "Nimble" - } - ], - "role" : "article", - "roleHeading" : "Article", - "title" : "Collection Elements" - }, - "primaryContentSections" : [ - { - "content" : [ - { - "anchor" : "Swift", - "level" : 2, - "text" : "Swift", - "type" : "heading" - }, - { - "inlineContent" : [ - { - "text" : "In Swift, the collection must be an instance of a type conforming to", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "code" : "Sequence", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "code" : [ - "\/\/ Swift", - "", - "\/\/ Providing a custom function:", - "expect([1, 2, 3, 4]).to(allPass { $0 < 5 })", - "", - "\/\/ Composing the expectation with another matcher:", - "expect([1, 2, 3, 4]).to(allPass(beLessThan(5)))" - ], - "syntax" : "swift", - "type" : "codeListing" - }, - { - "inlineContent" : [ - { - "text" : "There are also variants of ", - "type" : "text" - }, - { - "code" : "allPass", - "type" : "codeVoice" - }, - { - "text" : " that check against async matchers, and", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "that take in async functions:", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "code" : [ - "\/\/ Swift", - "", - "\/\/ Providing a custom function:", - "expect([1, 2, 3, 4]).to(allPass { await asyncFunctionReturningBool($0) })", - "", - "\/\/ Composing the expectation with another matcher:", - "expect([1, 2, 3, 4]).to(allPass(someAsyncMatcher()))" - ], - "syntax" : "swift", - "type" : "codeListing" - }, - { - "anchor" : "Objective-C", - "level" : 2, - "text" : "Objective-C", - "type" : "heading" - }, - { - "inlineContent" : [ - { - "text" : "In Objective-C, the collection must be an instance of a type which implements", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "the ", - "type" : "text" - }, - { - "code" : "NSFastEnumeration", - "type" : "codeVoice" - }, - { - "text" : " protocol, and whose elements are instances of a type", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "which subclasses ", - "type" : "text" - }, - { - "code" : "NSObject", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "inlineContent" : [ - { - "text" : "Additionally, unlike in Swift, there is no override to specify a custom", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "matcher function.", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "code" : [ - "\/\/ Objective-C", - "", - "expect(@[@1, @2, @3, @4]).to(allPass(beLessThan(@5)));" - ], - "syntax" : "objc", - "type" : "codeListing" - } - ], - "kind" : "content" - } - ], - "schemaVersion" : { - "major" : 0, - "minor" : 3, - "patch" : 0 - }, - "sections" : [ - - ], - "seeAlsoSections" : [ - { - "generated" : true, - "identifiers" : [ - "doc:\/\/Nimble\/documentation\/Nimble\/TypeChecking", - "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", - "doc:\/\/Nimble\/documentation\/Nimble\/Identity", - "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", - "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", - "doc:\/\/Nimble\/documentation\/Nimble\/SwiftAssertions", - "doc:\/\/Nimble\/documentation\/Nimble\/SwiftErrors", - "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", - "doc:\/\/Nimble\/documentation\/Nimble\/Strings", - "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", - "doc:\/\/Nimble\/documentation\/Nimble\/Result", - "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", - "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" - ], - "title" : "Matchers" - } - ], - "variants" : [ - { - "paths" : [ - "\/documentation\/nimble\/collectionelements" - ], - "traits" : [ - { - "interfaceLanguage" : "swift" - } - ] - } - ] -, -"references": { -"doc://Nimble/documentation/Nimble": { - "abstract" : [ - { - "inlineContent" : [ - { - "text" : "Nimble", - "type" : "text" - } - ], - "type" : "strong" - }, - { - "text" : " is a testing framework for verifying the outcomes and Swift or Objective-C expressions.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble", - "kind" : "symbol", - "role" : "collection", - "title" : "Nimble", - "type" : "topic", - "url" : "\/documentation\/nimble" -}, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", - "kind" : "article", - "role" : "article", - "title" : "Comparisons", - "type" : "topic", - "url" : "\/documentation\/nimble\/comparisons" -}, -"doc://Nimble/documentation/Nimble/CustomValidation": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "kind" : "article", - "role" : "article", - "title" : "Custom Validation", - "type" : "topic", - "url" : "\/documentation\/nimble\/customvalidation" -}, -"doc://Nimble/documentation/Nimble/Equivalence": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", - "kind" : "article", - "role" : "article", - "title" : "Equivalence", - "type" : "topic", - "url" : "\/documentation\/nimble\/equivalence" -}, -"doc://Nimble/documentation/Nimble/Exceptions": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", - "kind" : "article", - "role" : "article", - "title" : "Exceptions", - "type" : "topic", - "url" : "\/documentation\/nimble\/exceptions" -}, -"doc://Nimble/documentation/Nimble/GroupsOfMatchers": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", - "kind" : "article", - "role" : "article", - "title" : "Matching a value to any of a group of matchers", - "type" : "topic", - "url" : "\/documentation\/nimble\/groupsofmatchers" -}, -"doc://Nimble/documentation/Nimble/Identity": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", - "kind" : "article", - "role" : "article", - "title" : "Identity", - "type" : "topic", - "url" : "\/documentation\/nimble\/identity" -}, -"doc://Nimble/documentation/Nimble/Map": { - "abstract" : [ - { - "text" : "Sometimes, you only want to match against a property or group of properties.", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "are equal to something else. For this, use the ", - "type" : "text" - }, - { - "code" : "map", - "type" : "codeVoice" - }, - { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", - "kind" : "article", - "role" : "article", - "title" : "Notifications", - "type" : "topic", - "url" : "\/documentation\/nimble\/notifications" -}, -"doc://Nimble/documentation/Nimble/Result": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", - "kind" : "article", - "role" : "article", - "title" : "Result", - "type" : "topic", - "url" : "\/documentation\/nimble\/result" -}, -"doc://Nimble/documentation/Nimble/Strings": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", - "kind" : "article", - "role" : "article", - "title" : "Strings", - "type" : "topic", - "url" : "\/documentation\/nimble\/strings" -}, -"doc://Nimble/documentation/Nimble/SwiftAssertions": { - "abstract" : [ - { - "text" : "If you’re using Swift, you can use the ", - "type" : "text" - }, - { - "code" : "throwAssertion", - "type" : "codeVoice" - }, - { - "text" : " matcher to check if an assertion is thrown (e.g. ", - "type" : "text" - }, - { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", - "type" : "text" - }, - { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", - "type" : "text" - }, - { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" - }, - { - "text" : " library.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/SwiftAssertions", - "kind" : "article", - "role" : "article", - "title" : "Swift Assertions", - "type" : "topic", - "url" : "\/documentation\/nimble\/swiftassertions" -}, -"doc://Nimble/documentation/Nimble/SwiftErrors": { - "abstract" : [ - { - "text" : "You can use the ", - "type" : "text" - }, - { - "code" : "throwError", - "type" : "codeVoice" - }, - { - "text" : " matcher to check if an error is thrown.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/SwiftErrors", - "kind" : "article", - "role" : "article", - "title" : "Swift Error Handling", - "type" : "topic", - "url" : "\/documentation\/nimble\/swifterrors" -}, -"doc://Nimble/documentation/Nimble/Truthiness": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", - "kind" : "article", - "role" : "article", - "title" : "Truthiness", - "type" : "topic", - "url" : "\/documentation\/nimble\/truthiness" -}, -"doc://Nimble/documentation/Nimble/TypeChecking": { - "abstract" : [ - { - "text" : "Nimble supports checking the type membership of any kind of object, whether", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "Objective-C conformant or not.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/TypeChecking", - "kind" : "article", - "role" : "article", - "title" : "Type Checking", - "type" : "topic", - "url" : "\/documentation\/nimble\/typechecking" -}, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ - { - "text" : "@mattgallagher", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" -}, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ - { - "text" : "CwlPreconditionTesting", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" -} -} -} \ No newline at end of file diff --git a/data/documentation/nimble/collectionmembership.json b/data/documentation/nimble/collections.json similarity index 64% rename from data/documentation/nimble/collectionmembership.json rename to data/documentation/nimble/collections.json index fac8fbfa0..bfca44613 100644 --- a/data/documentation/nimble/collectionmembership.json +++ b/data/documentation/nimble/collections.json @@ -1,4 +1,18 @@ { + "abstract" : [ + { + "text" : "Nimble allows you to easily check ", + "type" : "text" + }, + { + "code" : "Collection", + "type" : "codeVoice" + }, + { + "text" : "s.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -8,7 +22,7 @@ }, "identifier" : { "interfaceLanguage" : "swift", - "url" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership" + "url" : "doc:\/\/Nimble\/documentation\/Nimble\/Collections" }, "kind" : "article", "metadata" : { @@ -19,15 +33,335 @@ ], "role" : "article", "roleHeading" : "Article", - "title" : "Collection Membership" + "title" : "Collection" }, "primaryContentSections" : [ { "content" : [ { - "anchor" : "overview", + "anchor" : "Collection-Count", + "level" : 2, + "text" : "Collection Count", + "type" : "heading" + }, + { + "code" : [ + "\/\/ Swift", + "", + "\/\/ Passes if 'actual' contains the 'expected' number of elements:", + "expect(actual).to(haveCount(expected))", + "", + "\/\/ Passes if 'actual' does _not_ contain the 'expected' number of elements:", + "expect(actual).notTo(haveCount(expected))" + ], + "syntax" : "swift", + "type" : "codeListing" + }, + { + "code" : [ + "\/\/ Objective-C", + "", + "\/\/ Passes if 'actual' contains the 'expected' number of elements:", + "expect(actual).to(haveCount(expected))", + "", + "\/\/ Passes if 'actual' does _not_ contain the 'expected' number of elements:", + "expect(actual).notTo(haveCount(expected))" + ], + "syntax" : "objc", + "type" : "codeListing" + }, + { + "inlineContent" : [ + { + "text" : "For Swift, the actual value must be an instance of a type conforming to ", + "type" : "text" + }, + { + "code" : "Collection", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "For example, instances of ", + "type" : "text" + }, + { + "code" : "Array", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "Dictionary", + "type" : "codeVoice" + }, + { + "text" : ", or ", + "type" : "text" + }, + { + "code" : "Set", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "inlineContent" : [ + { + "text" : "For Objective-C, the actual value must be one of the following classes, or their subclasses:", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "items" : [ + { + "content" : [ + { + "inlineContent" : [ + { + "code" : "NSArray", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + { + "content" : [ + { + "inlineContent" : [ + { + "code" : "NSDictionary", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + { + "content" : [ + { + "inlineContent" : [ + { + "code" : "NSSet", + "type" : "codeVoice" + }, + { + "text" : ", or", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + }, + { + "content" : [ + { + "inlineContent" : [ + { + "code" : "NSHashTable", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + } + ] + } + ], + "type" : "unorderedList" + }, + { + "anchor" : "Collection-Elements", + "level" : 2, + "text" : "Collection Elements", + "type" : "heading" + }, + { + "anchor" : "Swift", + "level" : 3, + "text" : "Swift", + "type" : "heading" + }, + { + "inlineContent" : [ + { + "text" : "In Swift, the collection must be an instance of a type conforming to", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "Sequence", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "code" : [ + "\/\/ Swift", + "", + "\/\/ Providing a custom function:", + "expect([1, 2, 3, 4]).to(allPass { $0 < 5 })", + "", + "\/\/ Composing the expectation with another matcher:", + "expect([1, 2, 3, 4]).to(allPass(beLessThan(5)))" + ], + "syntax" : "swift", + "type" : "codeListing" + }, + { + "inlineContent" : [ + { + "text" : "There are also variants of ", + "type" : "text" + }, + { + "code" : "allPass", + "type" : "codeVoice" + }, + { + "text" : " that check against async matchers, and", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "that take in async functions:", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "code" : [ + "\/\/ Swift", + "", + "\/\/ Providing a custom function:", + "expect([1, 2, 3, 4]).to(allPass { await asyncFunctionReturningBool($0) })", + "", + "\/\/ Composing the expectation with another matcher:", + "expect([1, 2, 3, 4]).to(allPass(someAsyncMatcher()))" + ], + "syntax" : "swift", + "type" : "codeListing" + }, + { + "anchor" : "Objective-C", + "level" : 3, + "text" : "Objective-C", + "type" : "heading" + }, + { + "inlineContent" : [ + { + "text" : "In Objective-C, the collection must be an instance of a type which implements", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "the ", + "type" : "text" + }, + { + "code" : "NSFastEnumeration", + "type" : "codeVoice" + }, + { + "text" : " protocol, and whose elements are instances of a type", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "which subclasses ", + "type" : "text" + }, + { + "code" : "NSObject", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "inlineContent" : [ + { + "text" : "Additionally, unlike in Swift, there is no override to specify a custom", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "matcher function.", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "code" : [ + "\/\/ Objective-C", + "", + "expect(@[@1, @2, @3, @4]).to(allPass(beLessThan(@5)));" + ], + "syntax" : "objc", + "type" : "codeListing" + }, + { + "anchor" : "Collection-Membership", "level" : 2, - "text" : "Overview", + "text" : "Collection Membership", "type" : "heading" }, { @@ -535,35 +869,11 @@ }, "sections" : [ - ], - "seeAlsoSections" : [ - { - "generated" : true, - "identifiers" : [ - "doc:\/\/Nimble\/documentation\/Nimble\/TypeChecking", - "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", - "doc:\/\/Nimble\/documentation\/Nimble\/Identity", - "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", - "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", - "doc:\/\/Nimble\/documentation\/Nimble\/SwiftAssertions", - "doc:\/\/Nimble\/documentation\/Nimble\/SwiftErrors", - "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", - "doc:\/\/Nimble\/documentation\/Nimble\/Strings", - "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", - "doc:\/\/Nimble\/documentation\/Nimble\/Result", - "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", - "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" - ], - "title" : "Matchers" - } ], "variants" : [ { "paths" : [ - "\/documentation\/nimble\/collectionmembership" + "\/documentation\/nimble\/collections" ], "traits" : [ { @@ -597,279 +907,6 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { - "abstract" : [ - { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", - "kind" : "article", - "role" : "article", - "title" : "Comparisons", - "type" : "topic", - "url" : "\/documentation\/nimble\/comparisons" -}, -"doc://Nimble/documentation/Nimble/CustomValidation": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "kind" : "article", - "role" : "article", - "title" : "Custom Validation", - "type" : "topic", - "url" : "\/documentation\/nimble\/customvalidation" -}, -"doc://Nimble/documentation/Nimble/Equivalence": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", - "kind" : "article", - "role" : "article", - "title" : "Equivalence", - "type" : "topic", - "url" : "\/documentation\/nimble\/equivalence" -}, -"doc://Nimble/documentation/Nimble/Exceptions": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", - "kind" : "article", - "role" : "article", - "title" : "Exceptions", - "type" : "topic", - "url" : "\/documentation\/nimble\/exceptions" -}, -"doc://Nimble/documentation/Nimble/GroupsOfMatchers": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", - "kind" : "article", - "role" : "article", - "title" : "Matching a value to any of a group of matchers", - "type" : "topic", - "url" : "\/documentation\/nimble\/groupsofmatchers" -}, -"doc://Nimble/documentation/Nimble/Identity": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", - "kind" : "article", - "role" : "article", - "title" : "Identity", - "type" : "topic", - "url" : "\/documentation\/nimble\/identity" -}, -"doc://Nimble/documentation/Nimble/Map": { - "abstract" : [ - { - "text" : "Sometimes, you only want to match against a property or group of properties.", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "are equal to something else. For this, use the ", - "type" : "text" - }, - { - "code" : "map", - "type" : "codeVoice" - }, - { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", - "kind" : "article", - "role" : "article", - "title" : "Notifications", - "type" : "topic", - "url" : "\/documentation\/nimble\/notifications" -}, -"doc://Nimble/documentation/Nimble/Result": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", - "kind" : "article", - "role" : "article", - "title" : "Result", - "type" : "topic", - "url" : "\/documentation\/nimble\/result" -}, -"doc://Nimble/documentation/Nimble/Strings": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", - "kind" : "article", - "role" : "article", - "title" : "Strings", - "type" : "topic", - "url" : "\/documentation\/nimble\/strings" -}, -"doc://Nimble/documentation/Nimble/SwiftAssertions": { - "abstract" : [ - { - "text" : "If you’re using Swift, you can use the ", - "type" : "text" - }, - { - "code" : "throwAssertion", - "type" : "codeVoice" - }, - { - "text" : " matcher to check if an assertion is thrown (e.g. ", - "type" : "text" - }, - { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", - "type" : "text" - }, - { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", - "type" : "text" - }, - { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" - }, - { - "text" : " library.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/SwiftAssertions", - "kind" : "article", - "role" : "article", - "title" : "Swift Assertions", - "type" : "topic", - "url" : "\/documentation\/nimble\/swiftassertions" -}, -"doc://Nimble/documentation/Nimble/SwiftErrors": { - "abstract" : [ - { - "text" : "You can use the ", - "type" : "text" - }, - { - "code" : "throwError", - "type" : "codeVoice" - }, - { - "text" : " matcher to check if an error is thrown.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/SwiftErrors", - "kind" : "article", - "role" : "article", - "title" : "Swift Error Handling", - "type" : "topic", - "url" : "\/documentation\/nimble\/swifterrors" -}, -"doc://Nimble/documentation/Nimble/Truthiness": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", - "kind" : "article", - "role" : "article", - "title" : "Truthiness", - "type" : "topic", - "url" : "\/documentation\/nimble\/truthiness" -}, -"doc://Nimble/documentation/Nimble/TypeChecking": { - "abstract" : [ - { - "text" : "Nimble supports checking the type membership of any kind of object, whether", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "Objective-C conformant or not.", - "type" : "text" - } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/TypeChecking", - "kind" : "article", - "role" : "article", - "title" : "Type Checking", - "type" : "topic", - "url" : "\/documentation\/nimble\/typechecking" -}, "https://github.com/Quick/Nimble/issues/27": { "identifier" : "https:\/\/github.com\/Quick\/Nimble\/issues\/27", "title" : "for now", @@ -881,30 +918,6 @@ ], "type" : "link", "url" : "https:\/\/github.com\/Quick\/Nimble\/issues\/27" -}, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ - { - "text" : "@mattgallagher", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" -}, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ - { - "text" : "CwlPreconditionTesting", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" } } } \ No newline at end of file diff --git a/data/documentation/nimble/comparisons.json b/data/documentation/nimble/comparisons.json index 1c9a386dd..c81da895e 100644 --- a/data/documentation/nimble/comparisons.json +++ b/data/documentation/nimble/comparisons.json @@ -1,4 +1,10 @@ { + "abstract" : [ + { + "text" : "Comparing the expression with other values.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -385,10 +391,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -430,45 +433,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Nimble allows you to perform custom validation.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/CustomValidation": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -479,7 +449,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -490,7 +463,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -501,7 +477,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -512,7 +491,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -524,52 +506,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -580,7 +553,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -591,7 +595,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -611,33 +666,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -655,11 +700,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -672,7 +731,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -703,29 +765,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ { - "text" : "CwlPreconditionTesting", + "text" : "A Nimble matcher that succeeds when the actual expression throws an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/concurrency.json b/data/documentation/nimble/concurrency.json index 1fc648f0c..8265bb82d 100644 --- a/data/documentation/nimble/concurrency.json +++ b/data/documentation/nimble/concurrency.json @@ -43,7 +43,7 @@ "type" : "text" }, { - "code" : "expect", + "code" : "expecta(file:line:_:)-4z5rl", "type" : "codeVoice" }, { @@ -203,15 +203,16 @@ "type" : "text" }, { - "code" : "SyncExpectation", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/SyncExpectation", + "isActive" : true, + "type" : "reference" }, { "text" : ", you can use the ", "type" : "text" }, { - "code" : "expects", + "code" : "expects(file:line:_:)-1ojb4", "type" : "codeVoice" }, { @@ -276,8 +277,9 @@ "type" : "text" }, { - "code" : "AsyncMatcher", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/AsyncMatcher", + "isActive" : true, + "type" : "reference" }, { "text" : "s. This is most obviously useful", @@ -317,8 +319,9 @@ { "inlineContent" : [ { - "code" : "allPass", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/allPass(_:)-5avdc", + "isActive" : true, + "type" : "reference" } ], "type" : "paragraph" @@ -330,8 +333,9 @@ { "inlineContent" : [ { - "code" : "containElementSatisfying", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/containElementSatisfying(_:_:)-8omf3", + "isActive" : true, + "type" : "reference" } ], "type" : "paragraph" @@ -343,15 +347,16 @@ { "inlineContent" : [ { - "code" : "satisfyAllOf", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/satisfyAllOf(_:)-99ble", + "isActive" : true, + "type" : "reference" }, { "text" : " and the ", "type" : "text" }, { - "code" : "&&", + "code" : "&&(left:right:)", "type" : "codeVoice" }, { @@ -359,8 +364,9 @@ "type" : "text" }, { - "code" : "AsyncMatcher", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/AsyncMatcher", + "isActive" : true, + "type" : "reference" }, { "text" : " and", @@ -393,15 +399,16 @@ { "inlineContent" : [ { - "code" : "satisfyAnyOf", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/satisfyAnyOf(_:)-8groo", + "isActive" : true, + "type" : "reference" }, { "text" : " and the ", "type" : "text" }, { - "code" : "||", + "code" : "||(left:right:)", "type" : "codeVoice" }, { @@ -445,23 +452,33 @@ { "inlineContent" : [ { - "text" : "Note: Swift Concurrency support is different than the ", + "text" : "Note: Swift Concurrency support is different than the", "type" : "text" }, { - "code" : "toEventually", - "type" : "codeVoice" + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/AsyncExpectation\/toEventually(_:timeout:pollInterval:description:)-38brw", + "isActive" : true, + "type" : "reference" }, { "text" : "\/", "type" : "text" }, { - "code" : "toEventuallyNot", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/AsyncExpectation\/toEventuallyNot(_:timeout:pollInterval:description:)-4ez1r", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " ", + "type" : "text" }, { - "text" : " feature described in ", + "text" : "feature described in ", "type" : "text" }, { @@ -588,6 +605,272 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, +"doc://Nimble/documentation/Nimble/AsyncExpectation/toEventually(_:timeout:pollInterval:description:)-38brw": { + "abstract" : [ + { + "text" : "Tests the actual value using a matcher to match by checking continuously", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "at each pollInterval until the timeout is reached.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "toEventually" + }, + { + "kind" : "text", + "text" : "(" + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Value" + }, + { + "kind" : "text", + "text" : ">, " + }, + { + "kind" : "externalParam", + "text" : "timeout" + }, + { + "kind" : "text", + "text" : ": " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble0A12TimeIntervalO", + "text" : "NimbleTimeInterval" + }, + { + "kind" : "text", + "text" : ", " + }, + { + "kind" : "externalParam", + "text" : "pollInterval" + }, + { + "kind" : "text", + "text" : ": " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble0A12TimeIntervalO", + "text" : "NimbleTimeInterval" + }, + { + "kind" : "text", + "text" : ", " + }, + { + "kind" : "externalParam", + "text" : "description" + }, + { + "kind" : "text", + "text" : ": " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:SS", + "text" : "String" + }, + { + "kind" : "text", + "text" : "?) " + }, + { + "kind" : "keyword", + "text" : "async" + }, + { + "kind" : "text", + "text" : " -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble16AsyncExpectationV", + "text" : "AsyncExpectation" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Value" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/AsyncExpectation\/toEventually(_:timeout:pollInterval:description:)-38brw", + "kind" : "symbol", + "role" : "symbol", + "title" : "toEventually(_:timeout:pollInterval:description:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/asyncexpectation\/toeventually(_:timeout:pollinterval:description:)-38brw" +}, +"doc://Nimble/documentation/Nimble/AsyncExpectation/toEventuallyNot(_:timeout:pollInterval:description:)-4ez1r": { + "abstract" : [ + { + "text" : "Tests the actual value using a matcher to not match by checking", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "continuously at each pollInterval until the timeout is reached.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "toEventuallyNot" + }, + { + "kind" : "text", + "text" : "(" + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Value" + }, + { + "kind" : "text", + "text" : ">, " + }, + { + "kind" : "externalParam", + "text" : "timeout" + }, + { + "kind" : "text", + "text" : ": " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble0A12TimeIntervalO", + "text" : "NimbleTimeInterval" + }, + { + "kind" : "text", + "text" : ", " + }, + { + "kind" : "externalParam", + "text" : "pollInterval" + }, + { + "kind" : "text", + "text" : ": " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble0A12TimeIntervalO", + "text" : "NimbleTimeInterval" + }, + { + "kind" : "text", + "text" : ", " + }, + { + "kind" : "externalParam", + "text" : "description" + }, + { + "kind" : "text", + "text" : ": " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:SS", + "text" : "String" + }, + { + "kind" : "text", + "text" : "?) " + }, + { + "kind" : "keyword", + "text" : "async" + }, + { + "kind" : "text", + "text" : " -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble16AsyncExpectationV", + "text" : "AsyncExpectation" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Value" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/AsyncExpectation\/toEventuallyNot(_:timeout:pollInterval:description:)-4ez1r", + "kind" : "symbol", + "role" : "symbol", + "title" : "toEventuallyNot(_:timeout:pollInterval:description:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/asyncexpectation\/toeventuallynot(_:timeout:pollinterval:description:)-4ez1r" +}, "doc://Nimble/documentation/Nimble/AsyncMatcher": { "abstract" : [ { @@ -870,6 +1153,37 @@ "type" : "topic", "url" : "\/documentation\/nimble\/require" }, +"doc://Nimble/documentation/Nimble/SyncExpectation": { + "abstract" : [ + + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "struct" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "SyncExpectation" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/SyncExpectation", + "kind" : "symbol", + "navigatorTitle" : [ + { + "kind" : "identifier", + "text" : "SyncExpectation" + } + ], + "role" : "symbol", + "title" : "SyncExpectation", + "type" : "topic", + "url" : "\/documentation\/nimble\/syncexpectation" +}, "doc://Nimble/documentation/Nimble/WritingCustomMatchers": { "abstract" : [ { @@ -907,6 +1221,347 @@ "title" : "Writing Your Own Matchers", "type" : "topic", "url" : "\/documentation\/nimble\/writingcustommatchers" +}, +"doc://Nimble/documentation/Nimble/allPass(_:)-5avdc": { + "abstract" : [ + + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "allPass" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "S" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble12AsyncMatcherV", + "text" : "AsyncMatcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "S" + }, + { + "kind" : "text", + "text" : "." + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:ST7ElementQa", + "text" : "Element" + }, + { + "kind" : "text", + "text" : ">) -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble12AsyncMatcherV", + "text" : "AsyncMatcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "S" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/allPass(_:)-5avdc", + "kind" : "symbol", + "role" : "symbol", + "title" : "allPass(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/allpass(_:)-5avdc" +}, +"doc://Nimble/documentation/Nimble/containElementSatisfying(_:_:)-8omf3": { + "abstract" : [ + + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "containElementSatisfying" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "S" + }, + { + "kind" : "text", + "text" : ">(((" + }, + { + "kind" : "typeIdentifier", + "text" : "S" + }, + { + "kind" : "text", + "text" : "." + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:ST7ElementQa", + "text" : "Element" + }, + { + "kind" : "text", + "text" : ") " + }, + { + "kind" : "keyword", + "text" : "async" + }, + { + "kind" : "text", + "text" : " -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:Sb", + "text" : "Bool" + }, + { + "kind" : "text", + "text" : "), " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:SS", + "text" : "String" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble12AsyncMatcherV", + "text" : "AsyncMatcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "S" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/containElementSatisfying(_:_:)-8omf3", + "kind" : "symbol", + "role" : "symbol", + "title" : "containElementSatisfying(_:_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/containelementsatisfying(_:_:)-8omf3" +}, +"doc://Nimble/documentation/Nimble/satisfyAllOf(_:)-99ble": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual value matches with all of the matchers", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "provided in the variable list of matchers.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "satisfyAllOf" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(any " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble16AsyncableMatcherP", + "text" : "AsyncableMatcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">...) -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble12AsyncMatcherV", + "text" : "AsyncMatcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/satisfyAllOf(_:)-99ble", + "kind" : "symbol", + "role" : "symbol", + "title" : "satisfyAllOf(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/satisfyallof(_:)-99ble" +}, +"doc://Nimble/documentation/Nimble/satisfyAnyOf(_:)-8groo": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual value matches with any of the matchers", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "provided in the variable list of matchers.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "satisfyAnyOf" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(any " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble16AsyncableMatcherP", + "text" : "AsyncableMatcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">...) -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble12AsyncMatcherV", + "text" : "AsyncMatcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/satisfyAnyOf(_:)-8groo", + "kind" : "symbol", + "role" : "symbol", + "title" : "satisfyAnyOf(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/satisfyanyof(_:)-8groo" } } } \ No newline at end of file diff --git a/data/documentation/nimble/customvalidation.json b/data/documentation/nimble/customvalidation.json index 1b53ad57f..104f99713 100644 --- a/data/documentation/nimble/customvalidation.json +++ b/data/documentation/nimble/customvalidation.json @@ -1,4 +1,10 @@ { + "abstract" : [ + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -85,7 +91,15 @@ { "inlineContent" : [ { - "text" : "When using Polling Expectations be careful not to make state changes or run process intensive code since this closure will be ran many times.", + "text" : "When using Polling Expectations be careful not to make state changes", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "or run process intensive code since this closure will be ran many times.", "type" : "text" } ], @@ -124,10 +138,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -169,45 +180,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -218,7 +196,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -229,7 +210,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -240,7 +224,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -251,7 +238,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -263,52 +253,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -319,7 +300,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -330,7 +342,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -350,33 +413,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -394,11 +447,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -411,7 +478,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -442,29 +512,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ { - "text" : "CwlPreconditionTesting", + "text" : "A Nimble matcher that succeeds when the actual expression throws an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/equivalence.json b/data/documentation/nimble/equivalence.json index 5a2f3be96..35ac10ca6 100644 --- a/data/documentation/nimble/equivalence.json +++ b/data/documentation/nimble/equivalence.json @@ -1,4 +1,10 @@ { + "abstract" : [ + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -139,10 +145,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -184,45 +187,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -233,7 +203,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -244,7 +217,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -255,7 +231,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -266,7 +245,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -278,52 +260,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -334,7 +307,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -345,7 +349,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -365,33 +420,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -409,11 +454,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -426,7 +485,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -457,29 +519,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ { - "text" : "CwlPreconditionTesting", + "text" : "A Nimble matcher that succeeds when the actual expression throws an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/exceptions.json b/data/documentation/nimble/exceptions.json index 98e3f34a3..9b2503f30 100644 --- a/data/documentation/nimble/exceptions.json +++ b/data/documentation/nimble/exceptions.json @@ -1,4 +1,10 @@ { + "abstract" : [ + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -120,7 +126,7 @@ "type" : "codeVoice" }, { - "text" : " is currentl unavailable when Nimble is installed", + "text" : " is currently unavailable when Nimble is installed", "type" : "text" }, { @@ -167,10 +173,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -212,45 +215,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -261,7 +231,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -272,7 +245,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -283,7 +259,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -294,7 +273,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -306,52 +288,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -362,7 +335,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -373,7 +377,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -393,33 +448,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -437,11 +482,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" }, { - "text" : " matcher to check if an error is thrown.", + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -454,7 +513,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -485,41 +547,156 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/Quick/Nimble/issues/220#issuecomment-172667064": { - "identifier" : "https:\/\/github.com\/Quick\/Nimble\/issues\/220#issuecomment-172667064", - "title" : "#220", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "#220", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/Quick\/Nimble\/issues\/220#issuecomment-172667064" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression throws an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, { - "text" : "@mattgallagher", + "text" : "error of the specified type or from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", +"https://github.com/Quick/Nimble/issues/220#issuecomment-172667064": { + "identifier" : "https:\/\/github.com\/Quick\/Nimble\/issues\/220#issuecomment-172667064", + "title" : "#220", "titleInlineContent" : [ { - "text" : "CwlPreconditionTesting", + "text" : "#220", "type" : "text" } ], "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "url" : "https:\/\/github.com\/Quick\/Nimble\/issues\/220#issuecomment-172667064" } } } \ No newline at end of file diff --git a/data/documentation/nimble/groupsofmatchers.json b/data/documentation/nimble/groupsofmatchers.json index 6197ac28d..b8c91a68d 100644 --- a/data/documentation/nimble/groupsofmatchers.json +++ b/data/documentation/nimble/groupsofmatchers.json @@ -1,4 +1,10 @@ { + "abstract" : [ + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -154,10 +160,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -199,45 +202,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -248,7 +218,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -259,7 +232,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -270,7 +246,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -281,7 +260,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -293,52 +275,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -349,7 +322,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -360,7 +364,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -380,33 +435,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -424,11 +469,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -441,7 +500,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -472,29 +534,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ { - "text" : "CwlPreconditionTesting", + "text" : "A Nimble matcher that succeeds when the actual expression throws an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/identity.json b/data/documentation/nimble/identity.json index 0e1b09cdc..cc289ed4e 100644 --- a/data/documentation/nimble/identity.json +++ b/data/documentation/nimble/identity.json @@ -1,4 +1,10 @@ { + "abstract" : [ + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -163,6 +169,42 @@ ], "syntax" : "objc", "type" : "codeListing" + }, + { + "content" : [ + { + "inlineContent" : [ + { + "text" : "", + "type" : "text" + }, + { + "code" : "beIdenticalTo", + "type" : "codeVoice" + }, + { + "text" : " checks the pointer addresses. It does not use the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "Identifiable", + "type" : "codeVoice" + }, + { + "text" : " protocol to check for identity.", + "type" : "text" + } + ], + "type" : "paragraph" + } + ], + "name" : "Warning", + "style" : "warning", + "type" : "aside" } ], "kind" : "content" @@ -192,10 +234,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -237,45 +276,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -286,7 +292,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -297,7 +306,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -308,7 +320,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -319,7 +334,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -331,52 +349,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -387,7 +396,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -398,7 +438,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -418,33 +509,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -462,11 +543,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -479,7 +574,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -510,29 +608,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", + "type" : "text" + }, { - "text" : "@mattgallagher", + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression throws an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, { - "text" : "CwlPreconditionTesting", + "text" : "error of the specified type or from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/map.json b/data/documentation/nimble/map.json index b89eb9595..e309526f8 100644 --- a/data/documentation/nimble/map.json +++ b/data/documentation/nimble/map.json @@ -1,39 +1,7 @@ { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "are equal to something else. For this, use the ", - "type" : "text" - }, - { - "code" : "map", - "type" : "codeVoice" - }, - { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" } ], @@ -68,6 +36,47 @@ "text" : "Overview", "type" : "heading" }, + { + "inlineContent" : [ + { + "text" : "Sometimes, you only want to match against a property or group of properties.", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "For example, if you wanted to check that only one or a few properties of a value", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "are equal to something else. For this, use the ", + "type" : "text" + }, + { + "code" : "map", + "type" : "codeVoice" + }, + { + "text" : " matcher to convert a value", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "to another value and check it with a matcher.", + "type" : "text" + } + ], + "type" : "paragraph" + }, { "code" : [ "\/\/ Swift", @@ -282,10 +291,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", - "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation" ], "title" : "Matchers" } @@ -327,45 +333,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -376,7 +349,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -387,7 +363,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -398,7 +377,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -409,7 +391,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -420,7 +405,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -431,7 +419,30 @@ }, "doc://Nimble/documentation/Nimble/Notifications": { "abstract" : [ - + { + "text" : "Checking Notifications posted to ", + "type" : "text" + }, + { + "code" : "NotificationCenter", + "type" : "codeVoice" + }, + { + "text" : " or a", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "DistributedNotificationCenter", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -442,7 +453,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -453,7 +495,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -473,33 +566,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -517,11 +600,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -534,7 +631,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -565,29 +665,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, { - "text" : "@mattgallagher", + "text" : "error from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression throws an", + "type" : "text" + }, { - "text" : "CwlPreconditionTesting", + "text" : " ", "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/notifications.json b/data/documentation/nimble/notifications.json index fd26e6bfc..cb372bc6d 100644 --- a/data/documentation/nimble/notifications.json +++ b/data/documentation/nimble/notifications.json @@ -1,4 +1,30 @@ { + "abstract" : [ + { + "text" : "Checking Notifications posted to ", + "type" : "text" + }, + { + "code" : "NotificationCenter", + "type" : "codeVoice" + }, + { + "text" : " or a", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "DistributedNotificationCenter", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -106,10 +132,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -151,45 +174,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -200,7 +190,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -211,7 +204,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -222,7 +218,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -233,7 +232,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -244,7 +246,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -256,31 +261,37 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Result": { + "abstract" : [ { - "text" : "For example, if you wanted to check that only one or a few properties of a value", + "text" : "You can check the contents of a ", "type" : "text" }, { - "text" : " ", - "type" : "text" + "code" : "Result", + "type" : "codeVoice" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " type using the ", "type" : "text" }, { - "code" : "map", + "code" : "beSuccess", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", + "text" : " or", "type" : "text" }, { @@ -288,20 +299,13 @@ "type" : "text" }, { - "text" : "to another value and check it with a matcher.", + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Result": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -312,7 +316,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -332,33 +387,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -376,11 +421,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -393,7 +452,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -424,29 +486,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, { - "text" : "@mattgallagher", + "text" : "error from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression throws an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, { - "text" : "CwlPreconditionTesting", + "text" : "error of the specified type or from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/pollingexpectations.json b/data/documentation/nimble/pollingexpectations.json index 04cc5dfbf..82a5a6f79 100644 --- a/data/documentation/nimble/pollingexpectations.json +++ b/data/documentation/nimble/pollingexpectations.json @@ -166,736 +166,6 @@ ], "type" : "paragraph" }, - { - "content" : [ - { - "inlineContent" : [ - { - "text" : "It is a very common mistake to assume that ", - "type" : "text" - }, - { - "code" : "toEventuallyNot", - "type" : "codeVoice" - }, - { - "text" : " is the", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "opposite of ", - "type" : "text" - }, - { - "code" : "toEventually", - "type" : "codeVoice" - }, - { - "text" : ". For example, if you’re using a ", - "type" : "text" - }, - { - "identifier" : "https:\/\/github.com\/Quick\/swift-fakes\/blob\/main\/Sources\/Fakes\/Spy.swift", - "isActive" : true, - "type" : "reference" - }, - { - "text" : ",", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "you might be used to checking that it is called on a background thread by using", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "code" : "expect(spy).toEventually(beCalled())", - "type" : "codeVoice" - }, - { - "text" : ". If you want to check that a spy is not", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "called during some background behavior, you might be tempted to use ", - "type" : "text" - }, - { - "code" : "expect(spy).toEventuallyNot(beCalled())", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "All this will do is verify that, by the time the Expectation first runs, the spy", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "has not been called. At which point, that background behavior might not even have", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "run. The correct thing is to use ", - "type" : "text" - }, - { - "code" : "toNever", - "type" : "codeVoice" - }, - { - "text" : ", as in ", - "type" : "text" - }, - { - "code" : "expect(spy).toNever(beCalled())", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - } - ], - "type" : "paragraph" - } - ], - "name" : "Warning", - "style" : "warning", - "type" : "aside" - }, - { - "header" : "row", - "rows" : [ - [ - [ - { - "inlineContent" : [ - { - "text" : "Polling form", - "type" : "text" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "Pass Duration", - "type" : "text" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "Expected Matcher Result", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - ], - [ - [ - { - "inlineContent" : [ - { - "code" : "toEventually", - "type" : "codeVoice" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "Until pass", - "type" : "text" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "to match", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - ], - [ - [ - { - "inlineContent" : [ - { - "code" : "toEventuallyNot", - "type" : "codeVoice" - }, - { - "text" : "\/", - "type" : "text" - }, - { - "code" : "toNotEventually", - "type" : "codeVoice" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "Until pass", - "type" : "text" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "to not match", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - ], - [ - [ - { - "inlineContent" : [ - { - "code" : "toAlways", - "type" : "codeVoice" - }, - { - "text" : "\/", - "type" : "text" - }, - { - "code" : "alwaysTo", - "type" : "codeVoice" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "Until fail", - "type" : "text" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "to match", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - ], - [ - [ - { - "inlineContent" : [ - { - "code" : "toNever", - "type" : "codeVoice" - }, - { - "text" : "\/", - "type" : "text" - }, - { - "code" : "neverTo", - "type" : "codeVoice" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "Until fail", - "type" : "text" - } - ], - "type" : "paragraph" - } - ], - [ - { - "inlineContent" : [ - { - "text" : "to not match", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - ] - ], - "type" : "table" - }, - { - "anchor" : "Verifying-a-Matcher-will-Eventually-Match-or-stop-Matching", - "level" : 3, - "text" : "Verifying a Matcher will Eventually Match or stop Matching", - "type" : "heading" - }, - { - "inlineContent" : [ - { - "text" : "To verify that a value eventually matches or stops matching through the length", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "of the timeout, use ", - "type" : "text" - }, - { - "code" : "toEventually", - "type" : "codeVoice" - }, - { - "text" : " or ", - "type" : "text" - }, - { - "code" : "toEventuallyNot", - "type" : "codeVoice" - }, - { - "text" : "\/", - "type" : "text" - }, - { - "code" : "toNotEventually", - "type" : "codeVoice" - }, - { - "text" : ":", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "code" : [ - "\/\/ Swift", - "DispatchQueue.main.async {", - " ocean.add(\"dolphins\")", - " ocean.add(\"whales\")", - "}", - "expect(ocean).toEventually(contain(\"dolphins\", \"whales\"))" - ], - "syntax" : "swift", - "type" : "codeListing" - }, - { - "code" : [ - "\/\/ Objective-C", - "", - "dispatch_async(dispatch_get_main_queue(), ^{", - " [ocean add:@\"dolphins\"];", - " [ocean add:@\"whales\"];", - "});", - "expect(ocean).toEventually(contain(@\"dolphins\", @\"whales\"));" - ], - "syntax" : "objc", - "type" : "codeListing" - }, - { - "inlineContent" : [ - { - "text" : "In the above example, ", - "type" : "text" - }, - { - "code" : "ocean", - "type" : "codeVoice" - }, - { - "text" : " is constantly re-evaluated. If it ever", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "contains dolphins and whales, the expectation passes. If ", - "type" : "text" - }, - { - "code" : "ocean", - "type" : "codeVoice" - }, - { - "text" : " still", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "doesn’t contain them, even after being continuously re-evaluated for one", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "whole second, the expectation fails.", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "anchor" : "Verifying-a-Matcher-will-Never-or-Always-Match", - "level" : 3, - "text" : "Verifying a Matcher will Never or Always Match", - "type" : "heading" - }, - { - "inlineContent" : [ - { - "text" : "You can also test that a value always or never matches throughout the length of the timeout. Use ", - "type" : "text" - }, - { - "code" : "toNever", - "type" : "codeVoice" - }, - { - "text" : " and ", - "type" : "text" - }, - { - "code" : "toAlways", - "type" : "codeVoice" - }, - { - "text" : " for this:", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "code" : [ - "\/\/ Swift", - "ocean.add(\"dolphins\")", - "expect(ocean).toAlways(contain(\"dolphins\"))", - "expect(ocean).toNever(contain(\"hares\"))" - ], - "syntax" : "swift", - "type" : "codeListing" - }, - { - "code" : [ - "\/\/ Objective-C", - "[ocean add:@\"dolphins\"]", - "expect(ocean).toAlways(contain(@\"dolphins\"))", - "expect(ocean).toNever(contain(@\"hares\"))" - ], - "syntax" : "objc", - "type" : "codeListing" - }, - { - "anchor" : "Behaviors-of-different-forms-of-Polling", - "level" : 3, - "text" : "Behaviors of different forms of Polling", - "type" : "heading" - }, - { - "inlineContent" : [ - { - "text" : "Fundamentally, the behaviors of the different types of polling (", - "type" : "text" - }, - { - "code" : "toEventually", - "type" : "codeVoice" - }, - { - "text" : ",", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "code" : "toEventuallyNot", - "type" : "codeVoice" - }, - { - "text" : ", ", - "type" : "text" - }, - { - "code" : "toAlways", - "type" : "codeVoice" - }, - { - "text" : ", ", - "type" : "text" - }, - { - "code" : "toNever", - "type" : "codeVoice" - }, - { - "text" : ") are about the duration of the polling,", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "and what they’re looking for with regard to the Expectation.", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "inlineContent" : [ - { - "text" : "For example, ", - "type" : "text" - }, - { - "code" : "toEventually", - "type" : "codeVoice" - }, - { - "text" : " will run until the Expectation matches, while ", - "type" : "text" - }, - { - "code" : "toNever", - "type" : "codeVoice" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "will run so long as the Expectation dosen’t match. This effectively makes them", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "opposites.", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "content" : [ - { - "inlineContent" : [ - { - "text" : "It is a very common mistake to assume that ", - "type" : "text" - }, - { - "code" : "toEventuallyNot", - "type" : "codeVoice" - }, - { - "text" : " is the", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "opposite of ", - "type" : "text" - }, - { - "code" : "toEventually", - "type" : "codeVoice" - }, - { - "text" : ". For example, if you’re using a ", - "type" : "text" - }, - { - "identifier" : "https:\/\/github.com\/Quick\/swift-fakes\/blob\/main\/Sources\/Fakes\/Spy.swift", - "isActive" : true, - "overridingTitle" : "Swift Fakes Spy", - "overridingTitleInlineContent" : [ - { - "text" : "Swift Fakes Spy", - "type" : "text" - } - ], - "type" : "reference" - }, - { - "text" : ",", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "you might be used to checking that it is called on a background thread by using", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "code" : "expect(spy).toEventually(beCalled())", - "type" : "codeVoice" - }, - { - "text" : ". If you want to check that a spy is not", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "called during some background behavior, you might be tempted to use ", - "type" : "text" - }, - { - "code" : "expect(spy).toEventuallyNot(beCalled())", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "All this will do is verify that, by the time the Expectation first runs, the spy", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "has not been called. At which point, that background behavior might not even have", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "run. The correct thing is to use ", - "type" : "text" - }, - { - "code" : "toNever", - "type" : "codeVoice" - }, - { - "text" : ", as in ", - "type" : "text" - }, - { - "code" : "expect(spy).toNever(beCalled())", - "type" : "codeVoice" - }, - { - "text" : ".", - "type" : "text" - } - ], - "type" : "paragraph" - } - ], - "name" : "Warning", - "style" : "warning", - "type" : "aside" - }, { "header" : "row", "rows" : [ @@ -1101,6 +371,250 @@ ], "type" : "table" }, + { + "content" : [ + { + "inlineContent" : [ + { + "text" : "It is a very common mistake to conflate ", + "type" : "text" + }, + { + "code" : "toEventuallyNot", + "type" : "codeVoice" + }, + { + "text" : " with ", + "type" : "text" + }, + { + "code" : "toNever", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "toEventuallyNot", + "type" : "codeVoice" + }, + { + "text" : " runs intil the first time the matcher doesn’t match. ", + "type" : "text" + }, + { + "code" : "toNever", + "type" : "codeVoice" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "continously polls so long as the matcher doesn’t match. Be mindful of the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "behavior you expect to observe, and be sure to check that your Polling", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "Expectation is not falsely matching.", + "type" : "text" + } + ], + "type" : "paragraph" + } + ], + "name" : "Warning", + "style" : "warning", + "type" : "aside" + }, + { + "anchor" : "Verifying-a-Matcher-will-Eventually-Match-or-stop-Matching", + "level" : 3, + "text" : "Verifying a Matcher will Eventually Match or stop Matching", + "type" : "heading" + }, + { + "inlineContent" : [ + { + "text" : "To verify that a value eventually matches or stops matching through the length", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "of the timeout, use ", + "type" : "text" + }, + { + "code" : "toEventually", + "type" : "codeVoice" + }, + { + "text" : " or ", + "type" : "text" + }, + { + "code" : "toEventuallyNot", + "type" : "codeVoice" + }, + { + "text" : "\/", + "type" : "text" + }, + { + "code" : "toNotEventually", + "type" : "codeVoice" + }, + { + "text" : ":", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "code" : [ + "\/\/ Swift", + "DispatchQueue.main.async {", + " ocean.add(\"dolphins\")", + " ocean.add(\"whales\")", + "}", + "expect(ocean).toEventually(contain(\"dolphins\", \"whales\"))" + ], + "syntax" : "swift", + "type" : "codeListing" + }, + { + "code" : [ + "\/\/ Objective-C", + "", + "dispatch_async(dispatch_get_main_queue(), ^{", + " [ocean add:@\"dolphins\"];", + " [ocean add:@\"whales\"];", + "});", + "expect(ocean).toEventually(contain(@\"dolphins\", @\"whales\"));" + ], + "syntax" : "objc", + "type" : "codeListing" + }, + { + "inlineContent" : [ + { + "text" : "In the above example, ", + "type" : "text" + }, + { + "code" : "ocean", + "type" : "codeVoice" + }, + { + "text" : " is constantly re-evaluated. If it ever", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "contains dolphins and whales, the expectation passes. If ", + "type" : "text" + }, + { + "code" : "ocean", + "type" : "codeVoice" + }, + { + "text" : " still", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "doesn’t contain them, even after being continuously re-evaluated for one", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "whole second, the expectation fails.", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "anchor" : "Verifying-a-Matcher-will-Never-or-Always-Match", + "level" : 3, + "text" : "Verifying a Matcher will Never or Always Match", + "type" : "heading" + }, + { + "inlineContent" : [ + { + "text" : "You can also test that a value always or never matches throughout the length of the timeout. Use ", + "type" : "text" + }, + { + "code" : "toNever", + "type" : "codeVoice" + }, + { + "text" : " and ", + "type" : "text" + }, + { + "code" : "toAlways", + "type" : "codeVoice" + }, + { + "text" : " for this:", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "code" : [ + "\/\/ Swift", + "ocean.add(\"dolphins\")", + "expect(ocean).toAlways(contain(\"dolphins\"))", + "expect(ocean).toNever(contain(\"hares\"))" + ], + "syntax" : "swift", + "type" : "codeListing" + }, + { + "code" : [ + "\/\/ Objective-C", + "[ocean add:@\"dolphins\"]", + "expect(ocean).toAlways(contain(@\"dolphins\"))", + "expect(ocean).toNever(contain(@\"hares\"))" + ], + "syntax" : "objc", + "type" : "codeListing" + }, { "anchor" : "Waiting-for-a-Callback-to-be-Called", "level" : 3, @@ -2013,18 +1527,6 @@ ], "type" : "link", "url" : "https:\/\/github.com\/Quick\/Quick\/blob\/main\/Documentation\/en-us\/ConfiguringQuick.md" -}, -"https://github.com/Quick/swift-fakes/blob/main/Sources/Fakes/Spy.swift": { - "identifier" : "https:\/\/github.com\/Quick\/swift-fakes\/blob\/main\/Sources\/Fakes\/Spy.swift", - "title" : "Swift Fakes Spy", - "titleInlineContent" : [ - { - "text" : "Swift Fakes Spy", - "type" : "text" - } - ], - "type" : "link", - "url" : "https:\/\/github.com\/Quick\/swift-fakes\/blob\/main\/Sources\/Fakes\/Spy.swift" } } } \ No newline at end of file diff --git a/data/documentation/nimble/result.json b/data/documentation/nimble/result.json index 696424340..4b95e68d0 100644 --- a/data/documentation/nimble/result.json +++ b/data/documentation/nimble/result.json @@ -1,4 +1,38 @@ { + "abstract" : [ + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -116,10 +150,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -161,45 +192,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -210,7 +208,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -221,7 +222,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -232,7 +236,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -243,7 +250,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -254,7 +264,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -266,52 +279,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -322,7 +326,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -342,33 +397,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -386,11 +431,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -403,7 +462,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -434,29 +496,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ { - "text" : "CwlPreconditionTesting", + "text" : "A Nimble matcher that succeeds when the actual expression throws an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/strings.json b/data/documentation/nimble/strings.json index 4cb9ba63b..00b3ac064 100644 --- a/data/documentation/nimble/strings.json +++ b/data/documentation/nimble/strings.json @@ -1,4 +1,58 @@ { + "abstract" : [ + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -30,6 +84,71 @@ "text" : "Overview", "type" : "heading" }, + { + "inlineContent" : [ + { + "text" : "The ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", and ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : " operate using substrings,", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "while the ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matcher checks if the string matches the given regular", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "expression.", + "type" : "text" + } + ], + "type" : "paragraph" + }, { "code" : [ "\/\/ Swift", @@ -102,10 +221,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -147,45 +263,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -196,7 +279,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -207,7 +293,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -218,7 +307,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -229,7 +321,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -240,7 +335,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -252,52 +350,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -308,7 +397,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -328,33 +448,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -372,11 +482,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -389,7 +513,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -420,29 +547,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ { - "text" : "CwlPreconditionTesting", + "text" : "A Nimble matcher that succeeds when the actual expression throws an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/swiftassertions.json b/data/documentation/nimble/swiftassertions.json index 21c3fee05..874ce226f 100644 --- a/data/documentation/nimble/swiftassertions.json +++ b/data/documentation/nimble/swiftassertions.json @@ -9,33 +9,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -70,6 +60,37 @@ "text" : "Overview", "type" : "heading" }, + { + "inlineContent" : [ + { + "text" : "This is made possible by ", + "type" : "text" + }, + { + "identifier" : "https:\/\/github.com\/mattgallagher", + "isActive" : true, + "type" : "reference" + }, + { + "text" : "’s", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " library.", + "type" : "text" + } + ], + "type" : "paragraph" + }, { "code" : [ "\/\/ Swift", @@ -99,52 +120,52 @@ "type" : "codeListing" }, { - "inlineContent" : [ - { - "text" : "Notes:", - "type" : "text" - } - ], - "type" : "paragraph" - }, - { - "items" : [ + "content" : [ { - "content" : [ + "inlineContent" : [ { - "inlineContent" : [ - { - "text" : "This feature is only available in Swift.", - "type" : "text" - } - ], - "type" : "paragraph" - } - ] - }, - { - "content" : [ + "text" : "This feature is only available in Swift.", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "Note: The tvOS simulator is supported, but using a different mechanism,", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, { - "inlineContent" : [ - { - "text" : "The tvOS simulator is supported, but using a different mechanism, requiring you to turn off the ", - "type" : "text" - }, - { - "code" : "Debug executable", - "type" : "codeVoice" - }, - { - "text" : " scheme setting for your tvOS scheme’s Test configuration.", - "type" : "text" - } - ], - "type" : "paragraph" + "text" : "requiring you to turn off the ", + "type" : "text" + }, + { + "code" : "Debug executable", + "type" : "codeVoice" + }, + { + "text" : " scheme setting for your tvOS", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "scheme’s Test configuration.", + "type" : "text" } - ] + ], + "type" : "paragraph" } ], - "type" : "unorderedList" + "name" : "Note", + "style" : "note", + "type" : "aside" } ], "kind" : "content" @@ -174,10 +195,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -219,45 +237,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -268,7 +253,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -279,7 +267,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -290,7 +281,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -301,7 +295,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -312,7 +309,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -324,52 +324,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -380,7 +371,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -391,7 +413,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -407,11 +480,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -424,7 +511,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -454,6 +544,169 @@ "title" : "Type Checking", "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" +}, +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" +}, +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression throws an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" +}, +"https://github.com/mattgallagher": { + "identifier" : "https:\/\/github.com\/mattgallagher", + "title" : "@mattgallagher", + "titleInlineContent" : [ + { + "text" : "@mattgallagher", + "type" : "text" + } + ], + "type" : "link", + "url" : "https:\/\/github.com\/mattgallagher" +}, +"https://github.com/mattgallagher/CwlPreconditionTesting": { + "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", + "title" : "CwlPreconditionTesting", + "titleInlineContent" : [ + { + "text" : "CwlPreconditionTesting", + "type" : "text" + } + ], + "type" : "link", + "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" } } } \ No newline at end of file diff --git a/data/documentation/nimble/swifterrors.json b/data/documentation/nimble/swifterrors.json index ca5534b2c..23e097c57 100644 --- a/data/documentation/nimble/swifterrors.json +++ b/data/documentation/nimble/swifterrors.json @@ -5,11 +5,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -44,6 +58,27 @@ "text" : "Overview", "type" : "heading" }, + { + "inlineContent" : [ + { + "code" : "throwError", + "type" : "codeVoice" + }, + { + "text" : " operates on errors that expressions throw using ", + "type" : "text" + }, + { + "code" : "try", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + }, { "code" : [ "\/\/ Swift", @@ -254,10 +289,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -299,45 +331,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -348,7 +347,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -359,7 +361,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -370,7 +375,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -381,7 +389,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -392,7 +403,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -404,52 +418,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -460,7 +465,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -471,7 +507,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -491,33 +578,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -530,7 +607,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -561,29 +641,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression throws an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, { - "text" : "CwlPreconditionTesting", + "text" : "error of the specified type or from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/truthiness.json b/data/documentation/nimble/truthiness.json index 7e6703d94..68fbdaa41 100644 --- a/data/documentation/nimble/truthiness.json +++ b/data/documentation/nimble/truthiness.json @@ -1,4 +1,10 @@ { + "abstract" : [ + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } + ], "hierarchy" : { "paths" : [ [ @@ -30,6 +36,165 @@ "text" : "Overview", "type" : "heading" }, + { + "inlineContent" : [ + { + "text" : "The ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/beTrue()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher matches only if the expression evaluates to ", + "type" : "text" + }, + { + "code" : "true", + "type" : "codeVoice" + }, + { + "text" : ", while", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "the ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/beTruthy()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher will also match if the expression also evaluates to a", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "non-", + "type" : "text" + }, + { + "code" : "nil", + "type" : "codeVoice" + }, + { + "text" : " value, or an object with a boolean value of ", + "type" : "text" + }, + { + "code" : "true", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "inlineContent" : [ + { + "text" : "Similarly, the ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/beFalse()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher matches only if the expression evaluates to", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "false", + "type" : "codeVoice" + }, + { + "text" : ", while the ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/beFalsy()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " also accepts ", + "type" : "text" + }, + { + "code" : "nil", + "type" : "codeVoice" + }, + { + "text" : ", or objects with a boolean", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "value of ", + "type" : "text" + }, + { + "code" : "false", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + }, + { + "inlineContent" : [ + { + "text" : "Finally, the ", + "type" : "text" + }, + { + "code" : "beNil())", + "type" : "codeVoice" + }, + { + "text" : " matcher matches only if the expression evaluates to", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "nil", + "type" : "codeVoice" + }, + { + "text" : ".", + "type" : "text" + } + ], + "type" : "paragraph" + }, { "code" : [ "\/\/ Passes if 'actual' is not nil, true, or an object with a boolean value of true:", @@ -100,10 +265,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -145,45 +307,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -194,7 +323,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -205,7 +337,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -216,7 +351,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -227,7 +365,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -238,7 +379,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -250,52 +394,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -306,7 +441,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -317,7 +483,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -337,33 +554,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -381,11 +588,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -418,29 +639,382 @@ "type" : "topic", "url" : "\/documentation\/nimble\/typechecking" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/beFalse()": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual value is exactly false.", + "type" : "text" + }, + { + "text" : " ", "type" : "text" + }, + { + "text" : "This matcher will not match against nils.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "beFalse" + }, + { + "kind" : "text", + "text" : "() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:Sb", + "text" : "Bool" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/beFalse()", + "kind" : "symbol", + "role" : "symbol", + "title" : "beFalse()", + "type" : "topic", + "url" : "\/documentation\/nimble\/befalse()" +}, +"doc://Nimble/documentation/Nimble/beFalsy()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual value is logically false.", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "This matcher will match against nils.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "beFalsy" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/beFalsy()", + "kind" : "symbol", + "role" : "symbol", + "title" : "beFalsy()", + "type" : "topic", + "url" : "\/documentation\/nimble\/befalsy()" +}, +"doc://Nimble/documentation/Nimble/beTrue()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual value is exactly true.", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "This matcher will not match against nils.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "beTrue" + }, + { + "kind" : "text", + "text" : "() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:Sb", + "text" : "Bool" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/beTrue()", + "kind" : "symbol", + "role" : "symbol", + "title" : "beTrue()", + "type" : "topic", + "url" : "\/documentation\/nimble\/betrue()" +}, +"doc://Nimble/documentation/Nimble/beTruthy()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual value is not logically false.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "beTruthy" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/beTruthy()", + "kind" : "symbol", + "role" : "symbol", + "title" : "beTruthy()", + "type" : "topic", + "url" : "\/documentation\/nimble\/betruthy()" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, { - "text" : "CwlPreconditionTesting", + "text" : "error from the specified case.", "type" : "text" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" +}, +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ + { + "text" : "A Nimble matcher that succeeds when the actual expression throws an", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/data/documentation/nimble/typechecking.json b/data/documentation/nimble/typechecking.json index 77f6e1438..d2bab385a 100644 --- a/data/documentation/nimble/typechecking.json +++ b/data/documentation/nimble/typechecking.json @@ -153,10 +153,7 @@ "doc:\/\/Nimble\/documentation\/Nimble\/Result", "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", - "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount" + "doc:\/\/Nimble\/documentation\/Nimble\/Map" ], "title" : "Matchers" } @@ -198,45 +195,12 @@ "type" : "topic", "url" : "\/documentation\/nimble" }, -"doc://Nimble/documentation/Nimble/CollectionCount": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionCount", - "kind" : "article", - "role" : "article", - "title" : "Collection Count", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectioncount" -}, -"doc://Nimble/documentation/Nimble/CollectionElements": { +"doc://Nimble/documentation/Nimble/Comparisons": { "abstract" : [ { - "text" : "Nimble provides a means to check that all elements of a collection pass a given expectation.", + "text" : "Comparing the expression with other values.", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionElements", - "kind" : "article", - "role" : "article", - "title" : "Collection Elements", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionelements" -}, -"doc://Nimble/documentation/Nimble/CollectionMembership": { - "abstract" : [ - - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CollectionMembership", - "kind" : "article", - "role" : "article", - "title" : "Collection Membership", - "type" : "topic", - "url" : "\/documentation\/nimble\/collectionmembership" -}, -"doc://Nimble/documentation/Nimble/Comparisons": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Comparisons", "kind" : "article", @@ -247,7 +211,10 @@ }, "doc://Nimble/documentation/Nimble/CustomValidation": { "abstract" : [ - + { + "text" : "Nimble allows you to perform custom validation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/CustomValidation", "kind" : "article", @@ -258,7 +225,10 @@ }, "doc://Nimble/documentation/Nimble/Equivalence": { "abstract" : [ - + { + "text" : "Checking if a value is equal to another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Equivalence", "kind" : "article", @@ -269,7 +239,10 @@ }, "doc://Nimble/documentation/Nimble/Exceptions": { "abstract" : [ - + { + "text" : "Check exceptions raised from Objective-C.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Exceptions", "kind" : "article", @@ -280,7 +253,10 @@ }, "doc://Nimble/documentation/Nimble/GroupsOfMatchers": { "abstract" : [ - + { + "text" : "Combining matchers into a single Expectation.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/GroupsOfMatchers", "kind" : "article", @@ -291,7 +267,10 @@ }, "doc://Nimble/documentation/Nimble/Identity": { "abstract" : [ - + { + "text" : "Checking if an object is the same address as another.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Identity", "kind" : "article", @@ -303,52 +282,43 @@ "doc://Nimble/documentation/Nimble/Map": { "abstract" : [ { - "text" : "Sometimes, you only want to match against a property or group of properties.", + "text" : "Mapping a value to another value in the matcher.", "type" : "text" - }, + } + ], + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", + "kind" : "article", + "role" : "article", + "title" : "Mapping a Value to Another Value", + "type" : "topic", + "url" : "\/documentation\/nimble\/map" +}, +"doc://Nimble/documentation/Nimble/Notifications": { + "abstract" : [ { - "text" : " ", + "text" : "Checking Notifications posted to ", "type" : "text" }, { - "text" : "For example, if you wanted to check that only one or a few properties of a value", - "type" : "text" + "code" : "NotificationCenter", + "type" : "codeVoice" }, { - "text" : " ", + "text" : " or a", "type" : "text" }, { - "text" : "are equal to something else. For this, use the ", + "text" : " ", "type" : "text" }, { - "code" : "map", + "code" : "DistributedNotificationCenter", "type" : "codeVoice" }, { - "text" : " matcher to convert a value", - "type" : "text" - }, - { - "text" : " ", - "type" : "text" - }, - { - "text" : "to another value and check it with a matcher.", + "text" : ".", "type" : "text" } - ], - "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Map", - "kind" : "article", - "role" : "article", - "title" : "Mapping a Value to Another Value", - "type" : "topic", - "url" : "\/documentation\/nimble\/map" -}, -"doc://Nimble/documentation/Nimble/Notifications": { - "abstract" : [ - ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Notifications", "kind" : "article", @@ -359,7 +329,38 @@ }, "doc://Nimble/documentation/Nimble/Result": { "abstract" : [ - + { + "text" : "You can check the contents of a ", + "type" : "text" + }, + { + "code" : "Result", + "type" : "codeVoice" + }, + { + "text" : " type using the ", + "type" : "text" + }, + { + "code" : "beSuccess", + "type" : "codeVoice" + }, + { + "text" : " or", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "code" : "beFailure", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Result", "kind" : "article", @@ -370,7 +371,58 @@ }, "doc://Nimble/documentation/Nimble/Strings": { "abstract" : [ - + { + "text" : "You can check strings using the ", + "type" : "text" + }, + { + "code" : "contain", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beginWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "endWith", + "type" : "codeVoice" + }, + { + "text" : ", ", + "type" : "text" + }, + { + "code" : "beEmpty", + "type" : "codeVoice" + }, + { + "text" : ",", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "and ", + "type" : "text" + }, + { + "code" : "match", + "type" : "codeVoice" + }, + { + "text" : " matchers.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Strings", "kind" : "article", @@ -390,33 +442,23 @@ "type" : "codeVoice" }, { - "text" : " matcher to check if an assertion is thrown (e.g. ", + "text" : " matcher to check if an", "type" : "text" }, { - "code" : "fatalError()", - "type" : "codeVoice" - }, - { - "text" : "). This is made possible by ", + "text" : " ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher", - "isActive" : true, - "type" : "reference" - }, - { - "text" : "’s ", + "text" : "assertion is thrown (e.g. ", "type" : "text" }, { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "isActive" : true, - "type" : "reference" + "code" : "fatalError()", + "type" : "codeVoice" }, { - "text" : " library.", + "text" : ").", "type" : "text" } ], @@ -434,11 +476,25 @@ "type" : "text" }, { - "code" : "throwError", - "type" : "codeVoice" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "isActive" : true, + "type" : "reference" + }, + { + "text" : " matcher to check if an error is thrown, and the", + "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "isActive" : true, + "type" : "reference" }, { - "text" : " matcher to check if an error is thrown.", + "text" : " to check already-captured errors.", "type" : "text" } ], @@ -451,7 +507,10 @@ }, "doc://Nimble/documentation/Nimble/Truthiness": { "abstract" : [ - + { + "text" : "Checking whether an expression is true, false, or nil.", + "type" : "text" + } ], "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/Truthiness", "kind" : "article", @@ -460,29 +519,144 @@ "type" : "topic", "url" : "\/documentation\/nimble\/truthiness" }, -"https://github.com/mattgallagher": { - "identifier" : "https:\/\/github.com\/mattgallagher", - "title" : "@mattgallagher", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/matchError(_:)-8o974": { + "abstract" : [ { - "text" : "@mattgallagher", + "text" : "A Nimble matcher that succeeds when the actual expression evaluates to an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "matchError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "T" + }, + { + "kind" : "text", + "text" : ">(" + }, + { + "kind" : "typeIdentifier", + "text" : "T" + }, + { + "kind" : "text", + "text" : ") -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/matchError(_:)-8o974", + "kind" : "symbol", + "role" : "symbol", + "title" : "matchError(_:)", + "type" : "topic", + "url" : "\/documentation\/nimble\/matcherror(_:)-8o974" }, -"https://github.com/mattgallagher/CwlPreconditionTesting": { - "identifier" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting", - "title" : "CwlPreconditionTesting", - "titleInlineContent" : [ +"doc://Nimble/documentation/Nimble/throwError()": { + "abstract" : [ { - "text" : "CwlPreconditionTesting", + "text" : "A Nimble matcher that succeeds when the actual expression throws an", "type" : "text" + }, + { + "text" : " ", + "type" : "text" + }, + { + "text" : "error of the specified type or from the specified case.", + "type" : "text" + } + ], + "fragments" : [ + { + "kind" : "keyword", + "text" : "func" + }, + { + "kind" : "text", + "text" : " " + }, + { + "kind" : "identifier", + "text" : "throwError" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "genericParameter", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">() -> " + }, + { + "kind" : "typeIdentifier", + "preciseIdentifier" : "s:6Nimble7MatcherV", + "text" : "Matcher" + }, + { + "kind" : "text", + "text" : "<" + }, + { + "kind" : "typeIdentifier", + "text" : "Out" + }, + { + "kind" : "text", + "text" : ">" } ], - "type" : "link", - "url" : "https:\/\/github.com\/mattgallagher\/CwlPreconditionTesting" + "identifier" : "doc:\/\/Nimble\/documentation\/Nimble\/throwError()", + "kind" : "symbol", + "role" : "symbol", + "title" : "throwError()", + "type" : "topic", + "url" : "\/documentation\/nimble\/throwerror()" } } } \ No newline at end of file diff --git a/documentation/nimble/collectionelements/index.html b/documentation/nimble/collectionelements/index.html deleted file mode 100755 index 50a79fe18..000000000 --- a/documentation/nimble/collectionelements/index.html +++ /dev/null @@ -1 +0,0 @@ -Documentation
\ No newline at end of file diff --git a/documentation/nimble/collectionmembership/index.html b/documentation/nimble/collectionmembership/index.html deleted file mode 100755 index 50a79fe18..000000000 --- a/documentation/nimble/collectionmembership/index.html +++ /dev/null @@ -1 +0,0 @@ -Documentation
\ No newline at end of file diff --git a/documentation/nimble/collectioncount/index.html b/documentation/nimble/collections/index.html similarity index 100% rename from documentation/nimble/collectioncount/index.html rename to documentation/nimble/collections/index.html diff --git a/index/index.json b/index/index.json index c1dc6e10b..ac7a1caeb 100644 --- a/index/index.json +++ b/index/index.json @@ -117,18 +117,12 @@ "type" : "article" }, { - "path" : "\/documentation\/nimble\/collectionmembership", - "title" : "Collection Membership", - "type" : "article" - }, - { - "path" : "\/documentation\/nimble\/collectionelements", - "title" : "Collection Elements", - "type" : "article" + "title" : "Articles", + "type" : "groupMarker" }, { - "path" : "\/documentation\/nimble\/collectioncount", - "title" : "Collection Count", + "path" : "\/documentation\/nimble\/collections", + "title" : "Collection", "type" : "article" }, {