|
111 | 111 | (assoc-in [:kaocha/cli-options :config-file] (str config-file))
|
112 | 112 | (assoc-in [:kaocha/tests 0 :kaocha/source-paths] [])
|
113 | 113 | (assoc-in [:kaocha/tests 0 :kaocha/test-paths] [(str test-dir)]))
|
| 114 | + ;; _ (println config) |
114 | 115 | prefix (str (gensym "foo"))
|
115 | 116 | finish? (atom false)
|
116 | 117 | q (w/make-queue)
|
|
132 | 133 | (w/qput q :finish)
|
133 | 134 | (Thread/sleep 100)
|
134 | 135 |
|
135 |
| - (let [split-str (str/split-lines @out-str)] |
136 |
| - (is (match? |
137 |
| - (matchers/embeds |
138 |
| - ["[(F)]" |
139 |
| - "" |
140 |
| - (str/replace "FAIL in foo.bar-test/xxx-test (bar_test.clj:1)" "foo" prefix) |
141 |
| - "Expected:" |
142 |
| - " :xxx" |
143 |
| - "Actual:" |
144 |
| - " -:xxx +:yyy" |
145 |
| - "1 tests, 1 assertions, 1 failures."]) |
146 |
| - split-str)) |
147 |
| - |
148 |
| - (is (match? |
149 |
| - (matchers/embeds |
150 |
| - [(format "bin/kaocha --config-file %s --focus '%s.bar-test/xxx-test'" (str config-file) prefix) |
151 |
| - "" |
152 |
| - (str/replace "[watch] Reloading #{foo.bar-test}" "foo" prefix) |
153 |
| - (str/replace "[watch] Re-running failed tests #{:foo.bar-test/xxx-test}" "foo" prefix) |
154 |
| - "[(F)]" |
155 |
| - "" |
156 |
| - (str/replace "FAIL in foo.bar-test/xxx-test (bar_test.clj:1)" "foo" prefix) |
157 |
| - "Expected:" |
158 |
| - " :xxx" |
159 |
| - "Actual:" |
160 |
| - " -:xxx +:zzz" ]) |
161 |
| - split-str))))) |
| 136 | + (is (match? |
| 137 | + (matchers/equals |
| 138 | + ["[(F)]" |
| 139 | + "" |
| 140 | + (str/replace "FAIL in foo.bar-test/xxx-test (bar_test.clj:1)" "foo" prefix) |
| 141 | + "Expected:" |
| 142 | + " :xxx" |
| 143 | + "Actual: " |
| 144 | + " -:xxx +:yyy" |
| 145 | + "1 tests, 1 assertions, 1 failures." |
| 146 | + "" |
| 147 | + (format "bin/kaocha --config-file %s --focus '%s.bar-test/xxx-test'" (str config-file) prefix) |
| 148 | + "" |
| 149 | + (str/replace "[watch] Reloading #{foo.bar-test}" "foo" prefix) |
| 150 | + (str/replace "[watch] Re-running failed tests #{:foo.bar-test/xxx-test}" "foo" prefix) |
| 151 | + "[(F)]" |
| 152 | + "" |
| 153 | + (str/replace "FAIL in foo.bar-test/xxx-test (bar_test.clj:1)" "foo" prefix) |
| 154 | + "Expected:" |
| 155 | + " :xxx" |
| 156 | + "Actual:" |
| 157 | + " -:xxx +:zzz" |
| 158 | + "1 tests, 1 assertions, 1 failures." |
| 159 | + "" |
| 160 | + (format "bin/kaocha --config-file %s --focus '%s.bar-test/xxx-test'" (str config-file) prefix) |
| 161 | + ]) |
| 162 | + (str/split-lines @out-str))))) |
162 | 163 |
|
163 | 164 | (deftest ignore-files-merged
|
164 | 165 | (let [{:keys [_config-file test-dir] :as m} (integration/test-dir-setup {})]
|
|
0 commit comments