 
               ;; wait until the flush is complete
               (is (true? (timed-deref flush-complete))
-                  "timed out waiting for the flush to complete"))
+                  (str "timed out waiting for the flush to complete, stack:\n"
+                       (get-all-stack-traces-as-str))))
 
             ;; we should have three instances with the constant and one without.
             (is (true? (check-jrubies-for-constant-counts pool-context 3 1)))))))))

        (is (= 503 (:status (ping-environment)))))
       (jruby-protocol/return-instance jruby-service jruby-instance :i-want-this-instance)
       (is (not= :timed-out (timed-deref stop-complete?))
           "timed out waiting for the stop to complete")
       (let [app-context (tk-app/app-context app)]
         ;; We have to re-initialize the JRubyPuppetService here because
         ;; otherwise the tk-app/stop that is included in the

          (is (= 503 (:status (ping-environment)))))
         (jruby-protocol/return-instance jruby-service jruby-instance :i-want-this-instance)
         (is (not= :timed-out (timed-deref stop-complete?))
             (str "timed out waiting for the stop to complete, stack:\n"
                  (get-all-stack-traces-as-str)))
         (logging/with-test-logging
          (is (= 503 (:status (ping-environment))))))))))

