Brought documentation up to date
This commit is contained in:
parent
66da871bb8
commit
0ae34c8ac1
35 changed files with 3894 additions and 1409 deletions
|
|
@ -62,460 +62,463 @@
|
|||
019 [dog-and-duck.quack.picky.control-variables :refer [*reject-severity*]]
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
020 [dog-and-duck.quack.picky.utils :refer [filter-severity object-faults]])
|
||||
020 [dog-and-duck.quack.picky.objects :refer [object-faults]]
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
021 [dog-and-duck.quack.picky.utils :refer [filter-severity]])
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
021
|
||||
022
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
022 (:import [java.net URI URISyntaxException]))
|
||||
023 (:import [java.net URI URISyntaxException]))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
023
|
||||
024
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
024 ;;; Copyright (C) Simon Brooke, 2022
|
||||
025 ;;; Copyright (C) Simon Brooke, 2022
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
025
|
||||
026
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
026 ;;; This program is free software; you can redistribute it and/or
|
||||
027 ;;; This program is free software; you can redistribute it and/or
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
027 ;;; modify it under the terms of the GNU General Public License
|
||||
028 ;;; modify it under the terms of the GNU General Public License
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
028 ;;; as published by the Free Software Foundation; either version 2
|
||||
029 ;;; as published by the Free Software Foundation; either version 2
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
029 ;;; of the License, or (at your option) any later version.
|
||||
030 ;;; of the License, or (at your option) any later version.
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
030
|
||||
031
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
031 ;;; This program is distributed in the hope that it will be useful,
|
||||
032 ;;; This program is distributed in the hope that it will be useful,
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
032 ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
033 ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
033 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
034 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
034 ;;; GNU General Public License for more details.
|
||||
035 ;;; GNU General Public License for more details.
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
035
|
||||
036
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
036 ;;; You should have received a copy of the GNU General Public License
|
||||
037 ;;; You should have received a copy of the GNU General Public License
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
037 ;;; along with this program; if not, write to the Free Software
|
||||
038 ;;; along with this program; if not, write to the Free Software
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
038 ;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
039 ;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
039
|
||||
040
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
040 (defn object?
|
||||
041 (defn object?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
041 "Returns `true` iff `x` is recognisably an ActivityStreams object.
|
||||
042 "Returns `true` iff `x` is recognisably an ActivityStreams object.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
042
|
||||
043
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
043 **NOTE THAT** The ActivityStreams spec
|
||||
044 **NOTE THAT** The ActivityStreams spec
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
044 [says](https://www.w3.org/TR/activitystreams-core/#object):
|
||||
045 [says](https://www.w3.org/TR/activitystreams-core/#object):
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
045
|
||||
046
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
046 > All properties are optional (including the id and type)
|
||||
047 > All properties are optional (including the id and type)
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
047
|
||||
048
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
048 But we are *just not having that*, because otherwise we're flying blind.
|
||||
049 But we are *just not having that*, because otherwise we're flying blind.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
049 We *shall* reject objects lacking at least `:type`. Missing `:id` keys are
|
||||
050 We *shall* reject objects lacking at least `:type`. Missing `:id` keys are
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
050 tolerable because they represent transient objects, which we expect to
|
||||
051 tolerable because they represent transient objects, which we expect to
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
051 handle.
|
||||
052 handle.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
052
|
||||
053
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
053 **NOTE THAT** The ActivityPub spec [says](https://www.w3.org/TR/activitypub/#obj)
|
||||
054 **NOTE THAT** The ActivityPub spec [says](https://www.w3.org/TR/activitypub/#obj)
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
054
|
||||
055
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
055 > Implementers SHOULD include the ActivityPub context in their object
|
||||
056 > Implementers SHOULD include the ActivityPub context in their object
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
056 > definitions
|
||||
057 > definitions
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
057
|
||||
058
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
058 but in samples found in the wild they typically don't."
|
||||
059 but in samples found in the wild they typically don't."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
059 ([x]
|
||||
060 ([x]
|
||||
</span><br/>
|
||||
<span class="covered" title="4 out of 4 forms covered">
|
||||
060 (object? x *reject-severity*))
|
||||
061 (object? x *reject-severity*))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
061 ([x severity]
|
||||
062 ([x severity]
|
||||
</span><br/>
|
||||
<span class="covered" title="8 out of 8 forms covered">
|
||||
062 (empty? (filter-severity (object-faults x) severity))))
|
||||
063 (empty? (filter-severity (object-faults x) severity))))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
063
|
||||
064
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
064 (defn persistent-object?
|
||||
065 (defn persistent-object?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
065 "`true` iff `x` is a persistent object.
|
||||
066 "`true` iff `x` is a persistent object.
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
066
|
||||
067
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
067 Transient objects in ActivityPub are not required to have an `id` key, but persistent
|
||||
068 Transient objects in ActivityPub are not required to have an `id` key, but persistent
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
068 ones must have a key, and it must be an IRI (but normally a URI)."
|
||||
069 ones must have a key, and it must be an IRI (but normally a URI)."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
069 ([x]
|
||||
070 ([x]
|
||||
</span><br/>
|
||||
<span class="covered" title="4 out of 4 forms covered">
|
||||
070 (persistent-object? x *reject-severity*))
|
||||
071 (persistent-object? x *reject-severity*))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
071 ([x severity]
|
||||
072 ([x severity]
|
||||
</span><br/>
|
||||
<span class="covered" title="8 out of 8 forms covered">
|
||||
072 (empty? (filter-severity (persistent-object-faults x) severity))))
|
||||
<span class="partial" title="7 out of 8 forms covered">
|
||||
073 (empty? (filter-severity (persistent-object-faults x) severity))))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
073
|
||||
074
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
074 (defn actor?
|
||||
075 (defn actor?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
075 "Returns `true` if `x` quacks like an actor, else false."
|
||||
076 "Returns `true` if `x` quacks like an actor, else false."
|
||||
</span><br/>
|
||||
<span class="covered" title="4 out of 4 forms covered">
|
||||
076 ([x] (actor? x *reject-severity*))
|
||||
077 ([x] (actor? x *reject-severity*))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
077 ([x severity]
|
||||
078 ([x severity]
|
||||
</span><br/>
|
||||
<span class="covered" title="8 out of 8 forms covered">
|
||||
078 (empty? (filter-severity (actor-faults x) severity))))
|
||||
079 (empty? (filter-severity (actor-faults x) severity))))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
079
|
||||
080
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
080 (defn actor-or-uri?
|
||||
081 (defn actor-or-uri?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
081 "`true` if `x` is either a URI or an actor.
|
||||
082 "`true` if `x` is either a URI or an actor.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
082
|
||||
083
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
083 **TODO**: I need to decide about whether to reify referenced objects
|
||||
084 **TODO**: I need to decide about whether to reify referenced objects
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
084 before validation or after. After reification, every reference to an actor
|
||||
085 before validation or after. After reification, every reference to an actor
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
085 *must be* to an actor object, but before, may only be to a URI pointing to
|
||||
086 *must be* to an actor object, but before, may only be to a URI pointing to
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
086 one."
|
||||
087 one."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
087 [x]
|
||||
088 [x]
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 3 forms covered">
|
||||
088 (try
|
||||
089 (try
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 5 forms covered">
|
||||
089 (and
|
||||
090 (and
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 9 forms covered">
|
||||
090 (cond (string? x) (uri? (URI. x))
|
||||
091 (cond (string? x) (uri? (URI. x))
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 3 forms covered">
|
||||
091 :else (actor? x))
|
||||
092 :else (actor? x))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
092 true)
|
||||
093 true)
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
093 (catch URISyntaxException _ false)
|
||||
094 (catch URISyntaxException _ false)
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
094 (catch NullPointerException _ false)))
|
||||
095 (catch NullPointerException _ false)))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
095
|
||||
096
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
096 (defn activity?
|
||||
097 (defn activity?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
097 "`true` iff `x` quacks like an activity, else false."
|
||||
098 "`true` iff `x` quacks like an activity, else false."
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 4 forms covered">
|
||||
098 ([x] (activity? x *reject-severity*))
|
||||
099 ([x] (activity? x *reject-severity*))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
099 ([x severity]
|
||||
100 ([x severity]
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 8 forms covered">
|
||||
100 (empty? (filter-severity (activity-faults x) severity))))
|
||||
101 (empty? (filter-severity (activity-faults x) severity))))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
101
|
||||
102
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
102 (defn link?
|
||||
103 (defn link?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
103 "`true` iff `x` quacks like a link, else false."
|
||||
104 "`true` iff `x` quacks like a link, else false."
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 4 forms covered">
|
||||
104 ([x] (link? x *reject-severity*))
|
||||
105 ([x] (link? x *reject-severity*))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
105 ([x severity]
|
||||
106 ([x severity]
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 8 forms covered">
|
||||
106 (empty? (filter-severity (link-faults x) severity))))
|
||||
107 (empty? (filter-severity (link-faults x) severity))))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
107
|
||||
108
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
108 (defn link-or-uri?
|
||||
109 (defn link-or-uri?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
109 "`true` iff `x` is either a URI or a link, else false.
|
||||
110 "`true` iff `x` is either a URI or a link, else false.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
110
|
||||
111
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
111 There are several points in the specification where e.g. the `:image`
|
||||
112 There are several points in the specification where e.g. the `:image`
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
112 property (if present) may be either a link or a URI."
|
||||
113 property (if present) may be either a link or a URI."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
113 [x]
|
||||
114 [x]
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 5 forms covered">
|
||||
114 (and
|
||||
115 (and
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 9 forms covered">
|
||||
115 (cond (string? x) (uri? (URI. x))
|
||||
116 (cond (string? x) (uri? (URI. x))
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 3 forms covered">
|
||||
116 :else (link? x))
|
||||
117 :else (link? x))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
117 true))
|
||||
118 true))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
118
|
||||
119
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
119 (defn collection?
|
||||
120 (defn collection?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
120 "`true` iff `x` quacks like a collection of type `object-type`, else `false`.
|
||||
121 "`true` iff `x` quacks like a collection of type `object-type`, else `false`.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
121
|
||||
122
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
122 With one argument, will recognise plain collections and ordered collections,
|
||||
123 With one argument, will recognise plain collections and ordered collections,
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
123 but (currently) not collection pages."
|
||||
124 but (currently) not collection pages."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
124 ([x ^String object-type]
|
||||
125 ([x ^String object-type]
|
||||
</span><br/>
|
||||
<span class="partial" title="10 out of 11 forms covered">
|
||||
125 (let [items (or (:items x) (:orderedItems x))]
|
||||
126 (let [items (or (:items x) (:orderedItems x))]
|
||||
</span><br/>
|
||||
<span class="partial" title="14 out of 17 forms covered">
|
||||
126 (and
|
||||
127 (and
|
||||
</span><br/>
|
||||
<span class="partial" title="5 out of 6 forms covered">
|
||||
127 (cond
|
||||
128 (cond
|
||||
</span><br/>
|
||||
<span class="partial" title="3 out of 8 forms covered">
|
||||
128 (:items x) (nil? (:orderedItems x))
|
||||
129 (:items x) (nil? (:orderedItems x))
|
||||
</span><br/>
|
||||
<span class="covered" title="8 out of 8 forms covered">
|
||||
129 (:orderedItems x) (nil? (:items x)) ;; can't have both properties
|
||||
130 (:orderedItems x) (nil? (:items x)) ;; can't have both properties
|
||||
</span><br/>
|
||||
<span class="covered" title="5 out of 5 forms covered">
|
||||
130 (integer? (:totalItems x)) true ;; can have neither, provided it has totalItems.
|
||||
131 (integer? (:totalItems x)) true ;; can have neither, provided it has totalItems.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
131 :else false)
|
||||
132 :else false)
|
||||
</span><br/>
|
||||
<span class="covered" title="3 out of 3 forms covered">
|
||||
132 (object? x)
|
||||
133 (object? x)
|
||||
</span><br/>
|
||||
<span class="covered" title="5 out of 5 forms covered">
|
||||
133 (= (:type x) object-type)
|
||||
134 (= (:type x) object-type)
|
||||
</span><br/>
|
||||
<span class="partial" title="2 out of 3 forms covered">
|
||||
134 (if items
|
||||
135 (if items
|
||||
</span><br/>
|
||||
<span class="partial" title="10 out of 12 forms covered">
|
||||
135 (and (coll? items)
|
||||
136 (and (coll? items)
|
||||
</span><br/>
|
||||
<span class="covered" title="4 out of 4 forms covered">
|
||||
136 (every? object? items) ;; if there are items, they must form a
|
||||
137 (every? object? items) ;; if there are items, they must form a
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
137 ;; collection of objects.
|
||||
138 ;; collection of objects.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
138 true)
|
||||
139 true)
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
139 true) ;; but it's OK if there aren't.
|
||||
140 true) ;; but it's OK if there aren't.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
140 true)
|
||||
141 true)
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
141 ;; test for totalItems not done here, because collection pages don't
|
||||
142 ;; test for totalItems not done here, because collection pages don't
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
142 ;; have it.
|
||||
143 ;; have it.
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
143 ))
|
||||
144 ))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
144 ([x]
|
||||
145 ([x]
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 9 forms covered">
|
||||
145 (and
|
||||
146 (and
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 10 forms covered">
|
||||
146 (or (collection? x "Collection")
|
||||
147 (or (collection? x "Collection")
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 2 forms covered">
|
||||
147 (collection? x "OrderedCollection"))
|
||||
148 (collection? x "OrderedCollection"))
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 5 forms covered">
|
||||
148 (integer? (:totalItems x))
|
||||
149 (integer? (:totalItems x))
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
149 true)))
|
||||
150 true)))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
150
|
||||
151
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
151 (defn unordered-collection?
|
||||
152 (defn unordered-collection?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
152 "`true` iff `x` quacks like an unordered collection, else `false`."
|
||||
153 "`true` iff `x` quacks like an unordered collection, else `false`."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
153 [x]
|
||||
154 [x]
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 18 forms covered">
|
||||
154 (and (collection? x "Collection") (integer? (:totalItems x)) true))
|
||||
155 (and (collection? x "Collection") (integer? (:totalItems x)) true))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
155
|
||||
156
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
156 (defn ordered-collection?
|
||||
157 (defn ordered-collection?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
157 "`true` iff `x` quacks like an ordered collection, else `false`."
|
||||
158 "`true` iff `x` quacks like an ordered collection, else `false`."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
158 [x]
|
||||
159 [x]
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 18 forms covered">
|
||||
159 (and (collection? x "OrderedCollection") (integer? (:totalItems x)) true))
|
||||
160 (and (collection? x "OrderedCollection") (integer? (:totalItems x)) true))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
160
|
||||
161
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
161 (defn collection-page?
|
||||
162 (defn collection-page?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
162 "`true` iff `x` quacks like a page in a paged collection, else `false`."
|
||||
163 "`true` iff `x` quacks like a page in a paged collection, else `false`."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
163 [x]
|
||||
164 [x]
|
||||
</span><br/>
|
||||
<span class="not-covered" title="0 out of 4 forms covered">
|
||||
164 (collection? x "CollectionPage"))
|
||||
165 (collection? x "CollectionPage"))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
165
|
||||
166
|
||||
</span><br/>
|
||||
<span class="covered" title="1 out of 1 forms covered">
|
||||
166 (defn ordered-collection-page?
|
||||
167 (defn ordered-collection-page?
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
167 "`true` iff `x` quacks like a page in an ordered paged collection, else `false`."
|
||||
168 "`true` iff `x` quacks like a page in an ordered paged collection, else `false`."
|
||||
</span><br/>
|
||||
<span class="not-tracked" title="0 out of 0 forms covered">
|
||||
168 [x]
|
||||
169 [x]
|
||||
</span><br/>
|
||||
<span class="covered" title="4 out of 4 forms covered">
|
||||
169 (collection? x "OrderedCollectionPage"))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
170
|
||||
170 (collection? x "OrderedCollectionPage"))
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
171
|
||||
</span><br/>
|
||||
<span class="blank" title="0 out of 0 forms covered">
|
||||
172
|
||||
</span><br/>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue