 (deftest short-circuit
   (checking
    "It stops searching when it finds a short circuit true pred"
-   (times 20)
+   (times 30)
    [false-1
     (gen/vector (->> :a
                      (flow-condition-gen)

   base-gen
   (fn [v]
     (let [g (gen/return ::true-pred)
           true-gen (gen/hash-map :flow/predicate g)]
       (gen/fmap #(merge v %) true-gen)))))

(defn false-flow-condition-gen [base-gen]

         results (t/route-data event nil nil flow-conditions downstream)]
     (is (not (seq (:flow results))))
     (is (= :retry (:action results))))))

(deftest key-exclusion
  (checking
   "Matched predicates excluded keys are conj'ed together"
   (times 30)
   [mixed
    (gen/vector
     (gen/one-of [(->> :a
                       (flow-condition-gen)
                       (flow-to-tasks-gen)
                       (true-flow-condition-gen))
                  (->> :a
                       (flow-condition-gen)
                       (flow-to-tasks-gen)
                       (false-flow-condition-gen))]))]
   (let [downstream (mapcat :flow/to mixed)
         compiled (c/compile-fc-norms mixed :a)
         event {:onyx.core/compiled-norm-fcs compiled}
         results (t/route-data event nil nil mixed downstream)
         matches (filter :pred/val mixed)
         excluded-keys (mapcat :flow/exclude-keys matches)]
     (prn excluded-keys)
     (is (into #{} excluded-keys) (:exclusions results))
     (is (nil? (:action results))))))
