     ;; flush the elastic index so that the updated index-set doc will be available
     (index/flush-elastic-index)
 
-    ;; this set up the environment variable that configures which collection will
-    ;; have its own granule index
+    ;; This set up the environment variable that configures which collection will
+    ;; have its own granule index. This is only for working in the REPL.
+    ;; When this test is run in CI the set variable will not influence the cmr-search-app
+    ;; or cmr-indexer-app which are running in a separate process.
+    ;; The CI script must set this environment variable to make those work.
     (config/set-config-value! :separate-coll-index "C1-SEP_PROV1,C2-SEP_PROV1")
     (ingest/reset)
     (ingest/create-provider "SEP_PROV1")


    (index/flush-elastic-index)

    (testing "search for granules in separate colletion index."
      (is (d/refs-match?
            [gran1 gran4]
            (search/find-refs :granule {"granule-ur[]" ["Granule1" "Granule4"]}))))

(ns cmr.system-int-test.search.granule-search-index-name-test
  "Integration tests for searching granules based on the configured index-names.
  This tests that the cmr-search-app and cmr-indexer-app will both put and find data in the correct granule index."
  (:require [clojure.test :refer :all]
            [cmr.common.config :as config]
            [cmr.system-int-test.utils.ingest-util :as ingest]
