Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Move Clojure.Source/clojure/test_clojure to Clojure.Tests

  • Loading branch information...
commit 6f9e5b3cefeea8e57fa0db4b6f3628b8ff140d46 1 parent f59049f
David Miller dmiller authored

Showing 65 changed files with 4,978 additions and 4,976 deletions. Show diff stats Hide diff stats

  1. +0 189 Clojure/Clojure.Source/Clojure.Source.csproj
  2. +191 0 Clojure/Clojure.Tests/Clojure.Tests.csproj
  3. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/run_tests.clj
  4. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/run_tests_i.clj
  5. +116 116 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/agents.clj
  6. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/atoms.clj
  7. +112 112 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/clojure_set.clj
  8. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/clojure_walk.clj
  9. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/clojure_xml.clj
  10. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/clojure_zip.clj
  11. +166 166 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/clr/io.clj
  12. +101 101 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/compilation.clj
  13. +305 305 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/control.clj
  14. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/data.clj
  15. +168 168 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/data_structures.clj
  16. +38 38 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/def.clj
  17. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/errors.clj
  18. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/evaluation.clj
  19. +3 3 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/for.clj
  20. +133 133 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/genclass.clj
  21. +87 87 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/genclass/examples.clj
  22. +53 53 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/java_interop.clj
  23. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/keywords.clj
  24. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/load.clj
  25. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/load/cyclic0.clj
  26. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/load/cyclic1.clj
  27. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/load/cyclic2.clj
  28. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/load/cyclic3.clj
  29. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/load/cyclic4.clj
  30. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/load/cyclic5.clj
  31. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/load/cyclic6.clj
  32. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/logic.clj
  33. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/macros.clj
  34. +52 52 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/main.clj
  35. +52 52 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/metadata.clj
  36. +137 137 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/multimethods.clj
  37. +68 68 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/ns_libs.clj
  38. +220 220 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/numbers.clj
  39. +233 233 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/other_functions.clj
  40. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/parallel.clj
  41. +19 19 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/pprint.clj
  42. +685 685 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/pprint/test_cl_format.clj
  43. +31 31 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/pprint/test_helper.clj
  44. +317 317 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/pprint/test_pretty.clj
  45. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/predicates.clj
  46. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/printer.clj
  47. +582 582 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/protocols.clj
  48. +12 12 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/protocols/examples.clj
  49. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/protocols/hash_collisions.clj
  50. +7 7 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/protocols/more_examples.clj
  51. +66 66 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/reader.clj
  52. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/refs.clj
  53. +31 31 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/repl.clj
  54. +5 5 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/repl/example.clj
  55. +83 83 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/rt.clj
  56. +176 176 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/sequences.clj
  57. +161 161 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/serialization.clj
  58. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/special.clj
  59. +118 118 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/string.clj
  60. +1 1  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/test.clj
  61. +2 2 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/test_fixtures.clj
  62. +25 25 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/transients.clj
  63. +51 51 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/vars.clj
  64. +371 371 Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_clojure/vectors.clj
  65. 0  Clojure/{Clojure.Source → Clojure.Tests}/clojure/test_helper.clj
189 Clojure/Clojure.Source/Clojure.Source.csproj
@@ -102,9 +102,6 @@
102 102 <None Include="clojure\reflect\clr.clj">
103 103 <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
104 104 </None>
105   - <None Include="clojure\run_tests_i.clj">
106   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
107   - </None>
108 105 <None Include="clojure\samples\ants.clj">
109 106 <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
110 107 </None>
@@ -177,153 +174,6 @@
177 174 <None Include="clojure\test\tap.clj">
178 175 <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
179 176 </None>
180   - <None Include="clojure\run_tests.clj">
181   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
182   - </None>
183   - <None Include="clojure\test_clojure\agents.clj">
184   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
185   - </None>
186   - <None Include="clojure\test_clojure\atoms.clj">
187   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
188   - </None>
189   - <None Include="clojure\test_clojure\clojure_set.clj">
190   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
191   - </None>
192   - <None Include="clojure\test_clojure\clojure_walk.clj">
193   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
194   - </None>
195   - <None Include="clojure\test_clojure\clojure_xml.clj">
196   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
197   - </None>
198   - <None Include="clojure\test_clojure\clojure_zip.clj">
199   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
200   - </None>
201   - <None Include="clojure\test_clojure\compilation.clj">
202   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
203   - </None>
204   - <None Include="clojure\test_clojure\control.clj">
205   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
206   - </None>
207   - <None Include="clojure\test_clojure\data.clj">
208   - <CopyToOutputDirectory>Always</CopyToOutputDirectory>
209   - </None>
210   - <None Include="clojure\test_clojure\data_structures.clj">
211   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
212   - </None>
213   - <None Include="clojure\test_clojure\errors.clj">
214   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
215   - </None>
216   - <None Include="clojure\test_clojure\evaluation.clj">
217   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
218   - </None>
219   - <None Include="clojure\test_clojure\for.clj">
220   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
221   - </None>
222   - <None Include="clojure\test_clojure\genclass.clj">
223   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
224   - </None>
225   - <None Include="clojure\test_clojure\genclass\examples.clj">
226   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
227   - </None>
228   - <None Include="clojure\test_clojure\java_interop.clj">
229   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
230   - </None>
231   - <None Include="clojure\test_clojure\keywords.clj">
232   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
233   - </None>
234   - <None Include="clojure\test_clojure\load.clj">
235   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
236   - </None>
237   - <None Include="clojure\test_clojure\load\cyclic3.clj">
238   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
239   - </None>
240   - <None Include="clojure\test_clojure\load\cyclic4.clj">
241   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
242   - </None>
243   - <None Include="clojure\test_clojure\load\cyclic5.clj">
244   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
245   - </None>
246   - <None Include="clojure\test_clojure\load\cyclic6.clj">
247   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
248   - </None>
249   - <None Include="clojure\test_clojure\load\cyclic2.clj">
250   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
251   - </None>
252   - <None Include="clojure\test_clojure\load\cyclic0.clj">
253   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
254   - </None>
255   - <None Include="clojure\test_clojure\load\cyclic1.clj">
256   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
257   - </None>
258   - <None Include="clojure\test_clojure\logic.clj">
259   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
260   - </None>
261   - <None Include="clojure\test_clojure\macros.clj">
262   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
263   - </None>
264   - <None Include="clojure\test_clojure\main.clj">
265   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
266   - </None>
267   - <None Include="clojure\test_clojure\metadata.clj">
268   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
269   - </None>
270   - <None Include="clojure\test_clojure\multimethods.clj">
271   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
272   - </None>
273   - <None Include="clojure\test_clojure\ns_libs.clj">
274   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
275   - </None>
276   - <None Include="clojure\test_clojure\numbers.clj">
277   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
278   - </None>
279   - <None Include="clojure\test_clojure\other_functions.clj">
280   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
281   - </None>
282   - <None Include="clojure\test_clojure\parallel.clj">
283   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
284   - </None>
285   - <None Include="clojure\test_clojure\predicates.clj">
286   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
287   - </None>
288   - <None Include="clojure\test_clojure\printer.clj">
289   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
290   - </None>
291   - <None Include="clojure\test_clojure\protocols.clj">
292   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
293   - </None>
294   - <None Include="clojure\test_clojure\protocols\examples.clj">
295   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
296   - </None>
297   - <None Include="clojure\test_clojure\protocols\hash_collisions.clj">
298   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
299   - </None>
300   - <None Include="clojure\test_clojure\protocols\more_examples.clj">
301   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
302   - </None>
303   - <None Include="clojure\test_clojure\reader.clj">
304   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
305   - </None>
306   - <None Include="clojure\test_clojure\refs.clj">
307   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
308   - </None>
309   - <None Include="clojure\test_clojure\sequences.clj">
310   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
311   - </None>
312   - <None Include="clojure\test_clojure\special.clj">
313   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
314   - </None>
315   - <None Include="clojure\test_clojure\test.clj">
316   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
317   - </None>
318   - <None Include="clojure\test_clojure\test_fixtures.clj">
319   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
320   - </None>
321   - <None Include="clojure\test_clojure\vars.clj">
322   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
323   - </None>
324   - <None Include="clojure\test_helper.clj">
325   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
326   - </None>
327 177 <None Include="clojure\uuid.clj">
328 178 <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
329 179 </None>
@@ -353,9 +203,6 @@
353 203 <None Include="clojure\string.clj">
354 204 <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
355 205 </None>
356   - <None Include="clojure\test_clojure\def.clj">
357   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
358   - </None>
359 206 <None Include="clojure\pprint.clj">
360 207 <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
361 208 </None>
@@ -383,42 +230,6 @@
383 230 <None Include="clojure\samples\stm\teststm.clj">
384 231 <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
385 232 </None>
386   - <None Include="clojure\test_clojure\clr\io.clj">
387   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
388   - </None>
389   - <None Include="clojure\test_clojure\pprint.clj">
390   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
391   - </None>
392   - <None Include="clojure\test_clojure\pprint\test_cl_format.clj">
393   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
394   - </None>
395   - <None Include="clojure\test_clojure\pprint\test_helper.clj">
396   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
397   - </None>
398   - <None Include="clojure\test_clojure\pprint\test_pretty.clj">
399   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
400   - </None>
401   - <None Include="clojure\test_clojure\repl\example.clj">
402   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
403   - </None>
404   - <None Include="clojure\test_clojure\repl.clj">
405   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
406   - </None>
407   - <None Include="clojure\test_clojure\rt.clj">
408   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
409   - </None>
410   - <None Include="clojure\test_clojure\serialization.clj">
411   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
412   - </None>
413   - <None Include="clojure\test_clojure\string.clj">
414   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
415   - </None>
416   - <None Include="clojure\test_clojure\transients.clj">
417   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
418   - </None>
419   - <None Include="clojure\test_clojure\vectors.clj">
420   - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
421   - </None>
422 233 </ItemGroup>
423 234 <ItemGroup>
424 235 <BootstrapperPackage Include="Microsoft.Net.Client.3.5">
191 Clojure/Clojure.Tests/Clojure.Tests.csproj
@@ -113,6 +113,197 @@
113 113 <Install>true</Install>
114 114 </BootstrapperPackage>
115 115 </ItemGroup>
  116 + <ItemGroup>
  117 + <None Include="clojure\run_tests.clj">
  118 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  119 + </None>
  120 + <None Include="clojure\run_tests_i.clj">
  121 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  122 + </None>
  123 + <None Include="clojure\test_clojure\agents.clj">
  124 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  125 + </None>
  126 + <None Include="clojure\test_clojure\atoms.clj">
  127 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  128 + </None>
  129 + <None Include="clojure\test_clojure\clojure_set.clj">
  130 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  131 + </None>
  132 + <None Include="clojure\test_clojure\clojure_walk.clj">
  133 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  134 + </None>
  135 + <None Include="clojure\test_clojure\clojure_xml.clj">
  136 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  137 + </None>
  138 + <None Include="clojure\test_clojure\clojure_zip.clj">
  139 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  140 + </None>
  141 + <None Include="clojure\test_clojure\clr\io.clj">
  142 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  143 + </None>
  144 + <None Include="clojure\test_clojure\compilation.clj">
  145 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  146 + </None>
  147 + <None Include="clojure\test_clojure\control.clj">
  148 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  149 + </None>
  150 + <None Include="clojure\test_clojure\data.clj">
  151 + <CopyToOutputDirectory>Always</CopyToOutputDirectory>
  152 + </None>
  153 + <None Include="clojure\test_clojure\data_structures.clj">
  154 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  155 + </None>
  156 + <None Include="clojure\test_clojure\def.clj">
  157 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  158 + </None>
  159 + <None Include="clojure\test_clojure\errors.clj">
  160 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  161 + </None>
  162 + <None Include="clojure\test_clojure\evaluation.clj">
  163 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  164 + </None>
  165 + <None Include="clojure\test_clojure\for.clj">
  166 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  167 + </None>
  168 + <None Include="clojure\test_clojure\genclass.clj">
  169 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  170 + </None>
  171 + <None Include="clojure\test_clojure\genclass\examples.clj">
  172 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  173 + </None>
  174 + <None Include="clojure\test_clojure\java_interop.clj">
  175 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  176 + </None>
  177 + <None Include="clojure\test_clojure\keywords.clj">
  178 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  179 + </None>
  180 + <None Include="clojure\test_clojure\load.clj">
  181 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  182 + </None>
  183 + <None Include="clojure\test_clojure\load\cyclic0.clj">
  184 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  185 + </None>
  186 + <None Include="clojure\test_clojure\load\cyclic1.clj">
  187 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  188 + </None>
  189 + <None Include="clojure\test_clojure\load\cyclic2.clj">
  190 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  191 + </None>
  192 + <None Include="clojure\test_clojure\load\cyclic3.clj">
  193 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  194 + </None>
  195 + <None Include="clojure\test_clojure\load\cyclic4.clj">
  196 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  197 + </None>
  198 + <None Include="clojure\test_clojure\load\cyclic5.clj">
  199 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  200 + </None>
  201 + <None Include="clojure\test_clojure\load\cyclic6.clj">
  202 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  203 + </None>
  204 + <None Include="clojure\test_clojure\logic.clj">
  205 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  206 + </None>
  207 + <None Include="clojure\test_clojure\macros.clj">
  208 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  209 + </None>
  210 + <None Include="clojure\test_clojure\main.clj">
  211 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  212 + </None>
  213 + <None Include="clojure\test_clojure\metadata.clj">
  214 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  215 + </None>
  216 + <None Include="clojure\test_clojure\multimethods.clj">
  217 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  218 + </None>
  219 + <None Include="clojure\test_clojure\ns_libs.clj">
  220 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  221 + </None>
  222 + <None Include="clojure\test_clojure\numbers.clj">
  223 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  224 + </None>
  225 + <None Include="clojure\test_clojure\other_functions.clj">
  226 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  227 + </None>
  228 + <None Include="clojure\test_clojure\parallel.clj">
  229 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  230 + </None>
  231 + <None Include="clojure\test_clojure\pprint.clj">
  232 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  233 + </None>
  234 + <None Include="clojure\test_clojure\pprint\test_cl_format.clj">
  235 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  236 + </None>
  237 + <None Include="clojure\test_clojure\pprint\test_helper.clj">
  238 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  239 + </None>
  240 + <None Include="clojure\test_clojure\pprint\test_pretty.clj">
  241 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  242 + </None>
  243 + <None Include="clojure\test_clojure\predicates.clj">
  244 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  245 + </None>
  246 + <None Include="clojure\test_clojure\printer.clj">
  247 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  248 + </None>
  249 + <None Include="clojure\test_clojure\protocols.clj">
  250 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  251 + </None>
  252 + <None Include="clojure\test_clojure\protocols\examples.clj">
  253 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  254 + </None>
  255 + <None Include="clojure\test_clojure\protocols\hash_collisions.clj">
  256 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  257 + </None>
  258 + <None Include="clojure\test_clojure\protocols\more_examples.clj">
  259 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  260 + </None>
  261 + <None Include="clojure\test_clojure\reader.clj">
  262 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  263 + </None>
  264 + <None Include="clojure\test_clojure\refs.clj">
  265 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  266 + </None>
  267 + <None Include="clojure\test_clojure\repl.clj">
  268 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  269 + </None>
  270 + <None Include="clojure\test_clojure\repl\example.clj">
  271 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  272 + </None>
  273 + <None Include="clojure\test_clojure\rt.clj">
  274 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  275 + </None>
  276 + <None Include="clojure\test_clojure\sequences.clj">
  277 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  278 + </None>
  279 + <None Include="clojure\test_clojure\serialization.clj">
  280 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  281 + </None>
  282 + <None Include="clojure\test_clojure\special.clj">
  283 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  284 + </None>
  285 + <None Include="clojure\test_clojure\string.clj">
  286 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  287 + </None>
  288 + <None Include="clojure\test_clojure\test.clj">
  289 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  290 + </None>
  291 + <None Include="clojure\test_clojure\test_fixtures.clj">
  292 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  293 + </None>
  294 + <None Include="clojure\test_clojure\transients.clj">
  295 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  296 + </None>
  297 + <None Include="clojure\test_clojure\vars.clj">
  298 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  299 + </None>
  300 + <None Include="clojure\test_clojure\vectors.clj">
  301 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  302 + </None>
  303 + <None Include="clojure\test_helper.clj">
  304 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  305 + </None>
  306 + </ItemGroup>
116 307 <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
117 308 <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
118 309 Other similar extension points exist, see Microsoft.Common.targets.
0  Clojure/Clojure.Source/clojure/run_tests.clj → Clojure/Clojure.Tests/clojure/run_tests.clj
File renamed without changes
0  Clojure/Clojure.Source/clojure/run_tests_i.clj → Clojure/Clojure.Tests/clojure/run_tests_i.clj
File renamed without changes
232 ...re/Clojure.Source/clojure/test_clojure/agents.clj → ...ure/Clojure.Tests/clojure/test_clojure/agents.clj
@@ -12,9 +12,9 @@
12 12 (:use clojure.test)
13 13 (:import [clojure.lang CountDownLatch])) ;;; [java.util.concurrent CountDownLatch TimeUnit]))
14 14
15   -;; tests are fragile. If wait fails, could indicate that
16   -;; build box is thrashing.
17   -(def fragile-wait 1000)
  15 +;; tests are fragile. If wait fails, could indicate that
  16 +;; build box is thrashing.
  17 +(def fragile-wait 1000)
18 18
19 19 (deftest handle-all-throwables-during-agent-actions
20 20 ;; Bug fixed in r1198; previously hung Clojure or didn't report agent errors
@@ -35,121 +35,121 @@
35 35 (is (true? (await-for fragile-wait agt)))
36 36 (is (true? @agt))))
37 37
38   -(deftest default-modes
39   - (is (= :fail (error-mode (agent nil))))
40   - (is (= :continue (error-mode (agent nil :error-handler println)))))
41   -
42   -(deftest continue-handler
43   - (let [err (atom nil)
44   - agt (agent 0 :error-mode :continue :error-handler #(reset! err %&))]
45   - (send agt /)
46   - (is (true? (await-for fragile-wait agt)))
47   - (is (= 0 @agt))
48   - (is (nil? (agent-error agt)))
49   - (is (= agt (first @err)))
50   - (is (true? (instance? ArithmeticException (second @err))))))
51   -
52   -(deftest fail-handler
53   - (let [err (atom nil)
54   - agt (agent 0 :error-mode :fail :error-handler #(reset! err %&))]
55   - (send agt /)
56   - (System.Threading.Thread/Sleep 100) ;;; Thread/sleep
57   - (is (true? (instance? ArithmeticException (agent-error agt))))
58   - (is (= 0 @agt))
59   - (is (= agt (first @err)))
60   - (is (true? (instance? ArithmeticException (second @err))))
61   - (is (thrown? Exception (send agt inc))))) ;;; RuntimeException
62   -
63   -(deftest can-send-from-error-handler-before-popping-action-that-caused-error
64   - (let [latch (CountDownLatch. 1)
65   - target-agent (agent :before-error)
66   - handler (fn [agt err]
67   - (send target-agent
68   - (fn [_] (.CountDown latch)))) ;;; .countDown
69   - failing-agent (agent nil :error-handler handler)]
70   - (send failing-agent (fn [_] (throw (Exception.)))) ;;; RuntimeException
71   - (is (.Await latch 10000)))) ;;; 10 TimeUnit/Seconds
72   -
73   -#_(deftest can-send-to-self-from-error-handler-before-popping-action-that-caused-error
74   - (let [latch (CountDownLatch. 1)
75   - handler (fn [agt err]
76   - (send *agent*
77   - (fn [_] (.CountDown latch)))) ;;; .countDown
78   - failing-agent (agent nil :error-handler handler)]
79   - (send failing-agent (fn [_] (throw (Exception.)))) ;;; RuntimeException
80   - (is (.Await latch 10000)))) ;;; .await 10 TimeUnit/Seconds
81   -
82   -(deftest restart-no-clear
83   - (let [p (promise)
84   - agt (agent 1 :error-mode :fail)]
85   - (send agt (fn [v] @p))
86   - (send agt /)
87   - (send agt inc)
88   - (send agt inc)
89   - (deliver p 0)
90   - (System.Threading.Thread/Sleep 100) ;;; Thread/sleep
91   - (is (= 0 @agt))
92   - (is (= ArithmeticException (class (agent-error agt))))
93   - (restart-agent agt 10)
94   - (is (true? (await-for fragile-wait agt)))
95   - (is (= 12 @agt))
96   - (is (nil? (agent-error agt)))))
97   -
98   -(deftest restart-clear
99   - (let [p (promise)
100   - agt (agent 1 :error-mode :fail)]
101   - (send agt (fn [v] @p))
102   - (send agt /)
103   - (send agt inc)
104   - (send agt inc)
105   - (deliver p 0)
106   - (System.Threading.Thread/Sleep 100) ;;; Thread/sleep
107   - (is (= 0 @agt))
108   - (is (= ArithmeticException (class (agent-error agt))))
109   - (restart-agent agt 10 :clear-actions true)
110   - (is (true? (await-for fragile-wait agt)))
111   - (is (= 10 @agt))
112   - (is (nil? (agent-error agt)))
113   - (send agt inc)
114   - (is (true? (await-for fragile-wait agt)))
115   - (is (= 11 @agt))
116   - (is (nil? (agent-error agt)))))
117   -
118   -(deftest invalid-restart
119   - (let [p (promise)
120   - agt (agent 2 :error-mode :fail :validator even?)]
121   - (is (thrown? Exception (restart-agent agt 4))) ;;; RuntimeException
122   - (send agt (fn [v] @p))
123   - (send agt (partial + 2))
124   - (send agt (partial + 2))
125   - (deliver p 3)
126   - (System.Threading.Thread/Sleep 100) ;;; Thread/sleep
127   - (is (= 2 @agt))
128   - (is (= InvalidOperationException (class (agent-error agt)))) ;;; IllegalStateException
129   - (is (thrown? Exception (restart-agent agt 5))) ;;; RuntimeException
130   - (restart-agent agt 6)
131   - (is (true? (await-for fragile-wait agt)))
132   - (is (= 10 @agt))
  38 +(deftest default-modes
  39 + (is (= :fail (error-mode (agent nil))))
  40 + (is (= :continue (error-mode (agent nil :error-handler println)))))
  41 +
  42 +(deftest continue-handler
  43 + (let [err (atom nil)
  44 + agt (agent 0 :error-mode :continue :error-handler #(reset! err %&))]
  45 + (send agt /)
  46 + (is (true? (await-for fragile-wait agt)))
  47 + (is (= 0 @agt))
  48 + (is (nil? (agent-error agt)))
  49 + (is (= agt (first @err)))
  50 + (is (true? (instance? ArithmeticException (second @err))))))
  51 +
  52 +(deftest fail-handler
  53 + (let [err (atom nil)
  54 + agt (agent 0 :error-mode :fail :error-handler #(reset! err %&))]
  55 + (send agt /)
  56 + (System.Threading.Thread/Sleep 100) ;;; Thread/sleep
  57 + (is (true? (instance? ArithmeticException (agent-error agt))))
  58 + (is (= 0 @agt))
  59 + (is (= agt (first @err)))
  60 + (is (true? (instance? ArithmeticException (second @err))))
  61 + (is (thrown? Exception (send agt inc))))) ;;; RuntimeException
  62 +
  63 +(deftest can-send-from-error-handler-before-popping-action-that-caused-error
  64 + (let [latch (CountDownLatch. 1)
  65 + target-agent (agent :before-error)
  66 + handler (fn [agt err]
  67 + (send target-agent
  68 + (fn [_] (.CountDown latch)))) ;;; .countDown
  69 + failing-agent (agent nil :error-handler handler)]
  70 + (send failing-agent (fn [_] (throw (Exception.)))) ;;; RuntimeException
  71 + (is (.Await latch 10000)))) ;;; 10 TimeUnit/Seconds
  72 +
  73 +#_(deftest can-send-to-self-from-error-handler-before-popping-action-that-caused-error
  74 + (let [latch (CountDownLatch. 1)
  75 + handler (fn [agt err]
  76 + (send *agent*
  77 + (fn [_] (.CountDown latch)))) ;;; .countDown
  78 + failing-agent (agent nil :error-handler handler)]
  79 + (send failing-agent (fn [_] (throw (Exception.)))) ;;; RuntimeException
  80 + (is (.Await latch 10000)))) ;;; .await 10 TimeUnit/Seconds
  81 +
  82 +(deftest restart-no-clear
  83 + (let [p (promise)
  84 + agt (agent 1 :error-mode :fail)]
  85 + (send agt (fn [v] @p))
  86 + (send agt /)
  87 + (send agt inc)
  88 + (send agt inc)
  89 + (deliver p 0)
  90 + (System.Threading.Thread/Sleep 100) ;;; Thread/sleep
  91 + (is (= 0 @agt))
  92 + (is (= ArithmeticException (class (agent-error agt))))
  93 + (restart-agent agt 10)
  94 + (is (true? (await-for fragile-wait agt)))
  95 + (is (= 12 @agt))
  96 + (is (nil? (agent-error agt)))))
  97 +
  98 +(deftest restart-clear
  99 + (let [p (promise)
  100 + agt (agent 1 :error-mode :fail)]
  101 + (send agt (fn [v] @p))
  102 + (send agt /)
  103 + (send agt inc)
  104 + (send agt inc)
  105 + (deliver p 0)
  106 + (System.Threading.Thread/Sleep 100) ;;; Thread/sleep
  107 + (is (= 0 @agt))
  108 + (is (= ArithmeticException (class (agent-error agt))))
  109 + (restart-agent agt 10 :clear-actions true)
  110 + (is (true? (await-for fragile-wait agt)))
  111 + (is (= 10 @agt))
  112 + (is (nil? (agent-error agt)))
  113 + (send agt inc)
  114 + (is (true? (await-for fragile-wait agt)))
  115 + (is (= 11 @agt))
  116 + (is (nil? (agent-error agt)))))
  117 +
  118 +(deftest invalid-restart
  119 + (let [p (promise)
  120 + agt (agent 2 :error-mode :fail :validator even?)]
  121 + (is (thrown? Exception (restart-agent agt 4))) ;;; RuntimeException
  122 + (send agt (fn [v] @p))
  123 + (send agt (partial + 2))
  124 + (send agt (partial + 2))
  125 + (deliver p 3)
  126 + (System.Threading.Thread/Sleep 100) ;;; Thread/sleep
  127 + (is (= 2 @agt))
  128 + (is (= InvalidOperationException (class (agent-error agt)))) ;;; IllegalStateException
  129 + (is (thrown? Exception (restart-agent agt 5))) ;;; RuntimeException
  130 + (restart-agent agt 6)
  131 + (is (true? (await-for fragile-wait agt)))
  132 + (is (= 10 @agt))
133 133 (is (nil? (agent-error agt)))))
134 134
135   -(deftest earmuff-agent-bound
136   - (let [a (agent 1)]
137   - (send a (fn [_] *agent*))
138   - (await a)
139   - (is (= a @a))))
140   -
141   -(def ^:dynamic *bind-me* :root-binding)
142   -
143   -(deftest thread-conveyance-to-agents
144   - (let [a (agent nil)]
145   - (doto (System.Threading.Thread.
146   - (gen-delegate System.Threading.ThreadStart []
147   - (binding [*bind-me* :thread-binding]
148   - (send a (constantly *bind-me*)))
149   - (await a)))
150   - (.Start)
151   - (.Join))
152   - (is (= @a :thread-binding))))
  135 +(deftest earmuff-agent-bound
  136 + (let [a (agent 1)]
  137 + (send a (fn [_] *agent*))
  138 + (await a)
  139 + (is (= a @a))))
  140 +
  141 +(def ^:dynamic *bind-me* :root-binding)
  142 +
  143 +(deftest thread-conveyance-to-agents
  144 + (let [a (agent nil)]
  145 + (doto (System.Threading.Thread.
  146 + (gen-delegate System.Threading.ThreadStart []
  147 + (binding [*bind-me* :thread-binding]
  148 + (send a (constantly *bind-me*)))
  149 + (await a)))
  150 + (.Start)
  151 + (.Join))
  152 + (is (= @a :thread-binding))))
153 153
154 154 ; http://clojure.org/agents
155 155
0  ...ure/Clojure.Source/clojure/test_clojure/atoms.clj → Clojure/Clojure.Tests/clojure/test_clojure/atoms.clj
File renamed without changes
224 ...ojure.Source/clojure/test_clojure/clojure_set.clj → ...lojure.Tests/clojure/test_clojure/clojure_set.clj
@@ -105,118 +105,118 @@
105 105 (hash-set 1 2) (hash-set 2 3)
106 106 (sorted-set 1 2) (sorted-set 2 3)) #{2} ))
107 107
108   -(deftest test-difference
109   - (are [x y] (= x y)
110   - ; identity
111   - (set/difference #{}) #{}
112   - (set/difference #{1}) #{1}
113   - (set/difference #{1 2 3}) #{1 2 3}
114   -
115   - ; 2 sets
116   - (set/difference #{1 2} #{1 2}) #{}
117   - (set/difference #{1 2} #{3 4}) #{1 2}
118   - (set/difference #{1 2} #{1}) #{2}
119   - (set/difference #{1 2} #{2}) #{1}
120   - (set/difference #{1 2 4} #{2 3 4 5}) #{1}
121   -
122   - ; 3 sets
123   - (set/difference #{1 2} #{2 3} #{5 2}) #{1}
124   - (set/difference #{1 2 3} #{1 3 4} #{1 3}) #{2}
125   - (set/difference #{1 2 3} #{3 4 5} #{8 2 3}) #{1} ))
126   -
127   -(deftest test-select
128   - (are [x y] (= x y)
129   - (set/select integer? #{}) #{}
130   - (set/select integer? #{1 2}) #{1 2}
131   - (set/select integer? #{1 2 :a :b :c}) #{1 2}
132   - (set/select integer? #{:a :b :c}) #{}) )
133   -
134   -(def compositions
135   - #{{:name "Art of the Fugue" :composer "J. S. Bach"}
136   - {:name "Musical Offering" :composer "J. S. Bach"}
137   - {:name "Requiem" :composer "Giuseppe Verdi"}
138   - {:name "Requiem" :composer "W. A. Mozart"}})
139   -
140   -(deftest test-project
141   - (are [x y] (= x y)
142   - (set/project compositions [:name]) #{{:name "Art of the Fugue"}
143   - {:name "Requiem"}
144   - {:name "Musical Offering"}}
145   - (set/project compositions [:composer]) #{{:composer "W. A. Mozart"}
146   - {:composer "Giuseppe Verdi"}
147   - {:composer "J. S. Bach"}}
148   - (set/project compositions [:year]) #{{}}
149   - (set/project #{{}} [:name]) #{{}} ))
150   -
151   -(deftest test-rename
152   - (are [x y] (= x y)
153   - (set/rename compositions {:name :title}) #{{:title "Art of the Fugue" :composer "J. S. Bach"}
154   - {:title "Musical Offering" :composer "J. S. Bach"}
155   - {:title "Requiem" :composer "Giuseppe Verdi"}
156   - {:title "Requiem" :composer "W. A. Mozart"}}
157   - (set/rename compositions {:year :decade}) #{{:name "Art of the Fugue" :composer "J. S. Bach"}
158   - {:name "Musical Offering" :composer "J. S. Bach"}
159   - {:name "Requiem" :composer "Giuseppe Verdi"}
160   - {:name "Requiem" :composer "W. A. Mozart"}}
161   - (set/rename #{{}} {:year :decade}) #{{}}))
162   -
163   -(deftest test-rename-keys
164   - (are [x y] (= x y)
165   - (set/rename-keys {:a "one" :b "two"} {:a :z}) {:z "one" :b "two"}
166   - ))
167   -
168   -(deftest test-index
169   - (are [x y] (= x y)
170   - (set/index #{{:c 2} {:b 1} {:a 1 :b 2}} [:b]) {{:b 2} #{{:a 1 :b 2}}, {:b 1} #{{:b 1}} {} #{{:c 2}}}
  108 +(deftest test-difference
  109 + (are [x y] (= x y)
  110 + ; identity
  111 + (set/difference #{}) #{}
  112 + (set/difference #{1}) #{1}
  113 + (set/difference #{1 2 3}) #{1 2 3}
  114 +
  115 + ; 2 sets
  116 + (set/difference #{1 2} #{1 2}) #{}
  117 + (set/difference #{1 2} #{3 4}) #{1 2}
  118 + (set/difference #{1 2} #{1}) #{2}
  119 + (set/difference #{1 2} #{2}) #{1}
  120 + (set/difference #{1 2 4} #{2 3 4 5}) #{1}
  121 +
  122 + ; 3 sets
  123 + (set/difference #{1 2} #{2 3} #{5 2}) #{1}
  124 + (set/difference #{1 2 3} #{1 3 4} #{1 3}) #{2}
  125 + (set/difference #{1 2 3} #{3 4 5} #{8 2 3}) #{1} ))
  126 +
  127 +(deftest test-select
  128 + (are [x y] (= x y)
  129 + (set/select integer? #{}) #{}
  130 + (set/select integer? #{1 2}) #{1 2}
  131 + (set/select integer? #{1 2 :a :b :c}) #{1 2}
  132 + (set/select integer? #{:a :b :c}) #{}) )
  133 +
  134 +(def compositions
  135 + #{{:name "Art of the Fugue" :composer "J. S. Bach"}
  136 + {:name "Musical Offering" :composer "J. S. Bach"}
  137 + {:name "Requiem" :composer "Giuseppe Verdi"}
  138 + {:name "Requiem" :composer "W. A. Mozart"}})
  139 +
  140 +(deftest test-project
  141 + (are [x y] (= x y)
  142 + (set/project compositions [:name]) #{{:name "Art of the Fugue"}
  143 + {:name "Requiem"}
  144 + {:name "Musical Offering"}}
  145 + (set/project compositions [:composer]) #{{:composer "W. A. Mozart"}
  146 + {:composer "Giuseppe Verdi"}
  147 + {:composer "J. S. Bach"}}
  148 + (set/project compositions [:year]) #{{}}
  149 + (set/project #{{}} [:name]) #{{}} ))
  150 +
  151 +(deftest test-rename
  152 + (are [x y] (= x y)
  153 + (set/rename compositions {:name :title}) #{{:title "Art of the Fugue" :composer "J. S. Bach"}
  154 + {:title "Musical Offering" :composer "J. S. Bach"}
  155 + {:title "Requiem" :composer "Giuseppe Verdi"}
  156 + {:title "Requiem" :composer "W. A. Mozart"}}
  157 + (set/rename compositions {:year :decade}) #{{:name "Art of the Fugue" :composer "J. S. Bach"}
  158 + {:name "Musical Offering" :composer "J. S. Bach"}
  159 + {:name "Requiem" :composer "Giuseppe Verdi"}
  160 + {:name "Requiem" :composer "W. A. Mozart"}}
  161 + (set/rename #{{}} {:year :decade}) #{{}}))
  162 +
  163 +(deftest test-rename-keys
  164 + (are [x y] (= x y)
  165 + (set/rename-keys {:a "one" :b "two"} {:a :z}) {:z "one" :b "two"}
  166 + ))
  167 +
  168 +(deftest test-index
  169 + (are [x y] (= x y)
  170 + (set/index #{{:c 2} {:b 1} {:a 1 :b 2}} [:b]) {{:b 2} #{{:a 1 :b 2}}, {:b 1} #{{:b 1}} {} #{{:c 2}}}
171 171 ))
172 172
173   -(deftest test-join
174   - (are [x y] (= x y)
175   - (set/join compositions compositions) compositions
176   - (set/join compositions #{{:name "Art of the Fugue" :genre "Classical"}})
177   - #{{:name "Art of the Fugue" :composer "J. S. Bach" :genre "Classical"}}
178   - ))
179   -
180   -(deftest test-map-invert
181   - (are [x y] (= x y)
182   - (set/map-invert {:a "one" :b "two"}) {"one" :a "two" :b}))
183   -
184   -(deftest test-subset?
185   - (are [sub super] (set/subset? sub super)
186   - #{} #{}
187   - #{} #{1}
188   - #{1} #{1}
189   - #{1 2} #{1 2}
190   - #{1 2} #{1 2 42}
191   - #{false} #{false}
192   - #{nil} #{nil}
193   - #{nil} #{nil false}
194   - #{1 2 nil} #{1 2 nil 4})
195   - (are [notsub super] (not (set/subset? notsub super))
196   - #{1} #{}
197   - #{2} #{1}
198   - #{1 3} #{1}
199   - #{nil} #{false}
200   - #{false} #{nil}
201   - #{false nil} #{nil}
202   - #{1 2 nil} #{1 2}))
203   -
204   -(deftest test-superset?
205   - (are [super sub] (set/superset? super sub)
206   - #{} #{}
207   - #{1} #{}
208   - #{1} #{1}
209   - #{1 2} #{1 2}
210   - #{1 2 42} #{1 2}
211   - #{false} #{false}
212   - #{nil} #{nil}
213   - #{false nil} #{false}
214   - #{1 2 4 nil false} #{1 2 nil})
215   - (are [notsuper sub] (not (set/superset? notsuper sub))
216   - #{} #{1}
217   - #{2} #{1}
218   - #{1} #{1 3}
219   - #{nil} #{false}
220   - #{false} #{nil}
221   - #{nil} #{false nil}
  173 +(deftest test-join
  174 + (are [x y] (= x y)
  175 + (set/join compositions compositions) compositions
  176 + (set/join compositions #{{:name "Art of the Fugue" :genre "Classical"}})
  177 + #{{:name "Art of the Fugue" :composer "J. S. Bach" :genre "Classical"}}
  178 + ))
  179 +
  180 +(deftest test-map-invert
  181 + (are [x y] (= x y)
  182 + (set/map-invert {:a "one" :b "two"}) {"one" :a "two" :b}))
  183 +
  184 +(deftest test-subset?
  185 + (are [sub super] (set/subset? sub super)
  186 + #{} #{}
  187 + #{} #{1}
  188 + #{1} #{1}
  189 + #{1 2} #{1 2}
  190 + #{1 2} #{1 2 42}
  191 + #{false} #{false}
  192 + #{nil} #{nil}
  193 + #{nil} #{nil false}
  194 + #{1 2 nil} #{1 2 nil 4})
  195 + (are [notsub super] (not (set/subset? notsub super))
  196 + #{1} #{}
  197 + #{2} #{1}
  198 + #{1 3} #{1}
  199 + #{nil} #{false}
  200 + #{false} #{nil}
  201 + #{false nil} #{nil}
  202 + #{1 2 nil} #{1 2}))
  203 +
  204 +(deftest test-superset?
  205 + (are [super sub] (set/superset? super sub)
  206 + #{} #{}
  207 + #{1} #{}
  208 + #{1} #{1}
  209 + #{1 2} #{1 2}
  210 + #{1 2 42} #{1 2}
  211 + #{false} #{false}
  212 + #{nil} #{nil}
  213 + #{false nil} #{false}
  214 + #{1 2 4 nil false} #{1 2 nil})
  215 + (are [notsuper sub] (not (set/superset? notsuper sub))
  216 + #{} #{1}
  217 + #{2} #{1}
  218 + #{1} #{1 3}
  219 + #{nil} #{false}
  220 + #{false} #{nil}
  221 + #{nil} #{false nil}
222 222 #{nil 2 3} #{false nil 2 3}))
0  ...jure.Source/clojure/test_clojure/clojure_walk.clj → ...ojure.Tests/clojure/test_clojure/clojure_walk.clj
File renamed without changes
0  ...ojure.Source/clojure/test_clojure/clojure_xml.clj → ...lojure.Tests/clojure/test_clojure/clojure_xml.clj
File renamed without changes
0  ...ojure.Source/clojure/test_clojure/clojure_zip.clj → ...lojure.Tests/clojure/test_clojure/clojure_zip.clj
File renamed without changes
332 ...re/Clojure.Source/clojure/test_clojure/clr/io.clj → ...ure/Clojure.Tests/clojure/test_clojure/clr/io.clj
... ... @@ -1,167 +1,167 @@
1   -; Copyright (c) Rich Hickey. All rights reserved.
2   -; The use and distribution terms for this software are covered by the
3   -; Eclipse Public License 1.0 (http://opensource.org/licenses/eclipse-1.0.php)
4   -; which can be found in the file epl-v10.html at the root of this distribution.
5   -; By using this software in any fashion, you are agreeing to be bound by
6   -; the terms of this license.
7   -; You must not remove this notice, or any other, from this software.
8   -
9   -
10   -
11   -(ns clojure.test-clojure.clr.io
12   - (:use clojure.test clojure.clr.io
13   - [clojure.test-helper :only [platform-newlines]])
14   - (:import
15   - (System.IO FileInfo FileMode FileStream StreamReader StreamWriter MemoryStream)
16   - (System.Text Encoding UTF8Encoding UnicodeEncoding)
17   - ))
18   -
19   -(def utf8 (UTF8Encoding.))
20   -(def utf16 (UnicodeEncoding.))
21   -
22   -(defn temp-file
23   - [fname]
24   - (let [fi (FileInfo. fname)]
25   - (when (.Exists fi)
26   - (.Delete fi))
27   - ;(doto (.Create fi) (.Close))
28   - fi))
29   -
30   -
31   -(defn- get-bytes [^String s ^Encoding encoding]
32   - (let [cs (.ToCharArray s)
33   - enc (.GetEncoder encoding)
34   - cnt (.GetByteCount enc cs 0 (.Length cs) true)
35   - bs (make-array Byte cnt)]
36   - (.GetBytes enc cs 0 (.Length cs) bs 0 true)
37   - bs))
38   -
39   -(deftest test-spit-and-slurp
40   - (let [f (temp-file "text")]
41   - (spit f "foobar")
42   - (is (= "foobar" (slurp f)))
43   - (spit f "foobar" :encoding utf16)
44   - (is (= "foobar" (slurp f :encoding utf16)))
45   - (testing "deprecated arity"
46   - (is (=
47   - (platform-newlines "WARNING: (slurp f enc) is deprecated, use (slurp f :encoding enc).\n")
48   - (with-out-str
49   - (is (= "foobar" (slurp f utf16)))))))))
50   -
51   -(deftest test-streams-defaults
52   - (let [f (temp-file "test-reader-writer")
53   - content "testing"]
54   - (try
55   - (is (thrown? Exception (text-reader (Object.))))
56   - (is (thrown? Exception (text-writer (Object.))))
57   -
58   - (are [write-to read-from] (= content (do
59   - (spit write-to content :encoding utf8)
60   - (slurp read-from :encoding utf8)))
61   - f f
62   - (.FullName f) (.FullName f)
63   - (FileStream. (.FullName f) FileMode/Create) (FileStream. (.FullName f) FileMode/Open)
64   - (StreamWriter. (FileStream. (.FullName f) FileMode/Create) utf8) (text-reader f :encoding utf8)
65   - f (FileStream. (.FullName f) FileMode/Open)
66   - (text-writer f :encoding utf8) (StreamReader. (FileStream. (.FullName f) FileMode/Open) utf8))
67   -
68   - (is (= content (slurp (get-bytes content utf8))))
69   - ;(is (= content (slurp (.ToCharArray content))))
70   - (finally
71   - (.Delete f)))))
72   -
73   -(defn bytes-should-equal [byte-array-1 byte-array-2 msg]
74   - (is (= |System.Byte[]| (class byte-array-1) (class byte-array-2)) msg)
75   - (is (= (into [] byte-array-1) (into [] byte-array-2)) msg))
76   -
77   -(defn data-fixture
78   - "in memory fixture data for tests"
79   - [in-encoding out-encoding]
80   - (let [bs (get-bytes "hello" in-encoding)
81   - i (MemoryStream. bs)
82   - r (StreamReader. i in-encoding)
83   - o (MemoryStream.)
84   - w (StreamWriter. o out-encoding )]
85   - {:bs bs
86   - :i i
87   - :r r
88   - :o o
89   - :s "hello"
90   - :w w}))
91   -
92   -(deftest test-copy
93   - (dorun
94   - (for [{:keys [in out flush] :as test}
95   - [{:in :i :out :o}
96   - {:in :i :out :w}
97   - {:in :r :out :o}
98   - {:in :r :out :w}
99   - {:in :bs :out :o}
100   - {:in :bs :out :w}]
101   -
102   - opts
103   - [{} {:buffer-size 256}]]
104   - (let [{:keys [s o] :as d} (data-fixture utf8 utf8)]
105   - (apply copy (in d) (out d) (flatten (vec opts)))
106   - #_(when (= out :w) (.Flush (:w d)))
107   - (.Flush (out d))
108   - (bytes-should-equal (get-bytes s utf8)
109   - (.ToArray o)
110   - (str "combination " test opts))))))
111   -
112   -(deftest test-copy-encodings
113   - (testing "from inputstream UTF-16 to writer UTF-8"
114   - (let [{:keys [i s o w bs]} (data-fixture utf16 utf8)]
115   - (copy i w :encoding utf16)
116   - (.Flush w)
117   - (bytes-should-equal (get-bytes s utf8) (.ToArray o) "")))
118   - (testing "from reader UTF-8 to output-stream UTF-16"
119   - (let [{:keys [r o s]} (data-fixture utf8 utf16)]
120   - (copy r o :encoding utf16)
121   - (bytes-should-equal (get-bytes s utf16) (.ToArray o) ""))))
122   -
123   -;(deftest test-as-file
124   -; (are [result input] (= result (as-file input))
125   -; (File. "foo") "foo"
126   -; (File. "bar") (File. "bar")
127   -; (File. "baz") (URL. "file:baz")
128   -; (File. "quux") (URI. "file:quux")
129   -; nil nil))
130   -
131   -;(deftest test-file
132   -; (are [result args] (= (File. result) (apply file args))
133   -; "foo" ["foo"]
134   -; "foo/bar" ["foo" "bar"]
135   -; "foo/bar/baz" ["foo" "bar" "baz"]))
136   -;(deftest test-as-url