nunit 2.4.8.0 → 2.5.0.9122

Sign up to get free protection for your applications and to get access to all the features.
Files changed (276) hide show
  1. data/docs/addinsDialog.html +36 -6
  2. data/docs/assertions.html +31 -12
  3. data/docs/attributes.html +59 -36
  4. data/docs/category.html +32 -9
  5. data/docs/collectionAssert.html +30 -12
  6. data/docs/collectionConstraints.html +242 -44
  7. data/docs/combinatorial.html +130 -0
  8. data/docs/comparisonAsserts.html +12 -9
  9. data/docs/comparisonConstraints.html +159 -25
  10. data/docs/compoundConstraints.html +12 -9
  11. data/docs/conditionAsserts.html +36 -12
  12. data/docs/conditionConstraints.html +131 -25
  13. data/docs/configEditor.html +10 -5
  14. data/docs/configFiles.html +5 -6
  15. data/docs/consoleCommandLine.html +51 -24
  16. data/docs/constraintModel.html +56 -19
  17. data/docs/contextMenu.html +10 -5
  18. data/docs/culture.html +32 -9
  19. data/docs/customConstraints.html +53 -37
  20. data/docs/datapoint.html +124 -0
  21. data/docs/datapointProviders.html +105 -0
  22. data/docs/delayedConstraint.html +98 -0
  23. data/docs/description.html +32 -9
  24. data/docs/directoryAssert.html +151 -0
  25. data/docs/equalConstraint.html +167 -47
  26. data/docs/equalityAsserts.html +12 -9
  27. data/docs/eventListeners.html +110 -0
  28. data/docs/exception.html +61 -36
  29. data/docs/exceptionAsserts.html +210 -0
  30. data/docs/explicit.html +32 -9
  31. data/docs/extensibility.html +8 -8
  32. data/docs/extensionTips.html +100 -0
  33. data/docs/fileAssert.html +12 -9
  34. data/docs/files/TestResult.xml +99 -67
  35. data/docs/fixtureSetup.html +60 -18
  36. data/docs/fixtureTeardown.html +56 -17
  37. data/docs/getStarted.html +9 -4
  38. data/docs/guiCommandLine.html +10 -5
  39. data/docs/identityAsserts.html +12 -9
  40. data/docs/ignore.html +32 -9
  41. data/docs/img/addinsDialog.JPG +0 -0
  42. data/docs/img/advancedSettings.jpg +0 -0
  43. data/docs/img/assembliesTab.jpg +0 -0
  44. data/docs/img/assemblyReloadSettings.JPG +0 -0
  45. data/docs/img/configEditor.jpg +0 -0
  46. data/docs/img/console-mock.jpg +0 -0
  47. data/docs/img/generalSettings.jpg +0 -0
  48. data/docs/img/generalTab.jpg +0 -0
  49. data/docs/img/gui-screenshot.jpg +0 -0
  50. data/docs/img/gui-verify.jpg +0 -0
  51. data/docs/img/miniGui.jpg +0 -0
  52. data/docs/img/testLoadSettings.jpg +0 -0
  53. data/docs/img/testOutputSettings.jpg +0 -0
  54. data/docs/img/testProperties.jpg +0 -0
  55. data/docs/img/testResultSettings.JPG +0 -0
  56. data/docs/img/textOutputSettings.jpg +0 -0
  57. data/docs/img/treeDisplaySettings.jpg +0 -0
  58. data/docs/img/visualStudioSettings.jpg +0 -0
  59. data/docs/index.html +15 -8
  60. data/docs/installation.html +33 -75
  61. data/docs/license.html +9 -4
  62. data/docs/listMapper.html +12 -9
  63. data/docs/mainMenu.html +18 -8
  64. data/docs/maxtime.html +109 -0
  65. data/docs/multiAssembly.html +5 -6
  66. data/docs/nunit-console.html +9 -4
  67. data/docs/nunit-gui.html +32 -15
  68. data/docs/nunit.css +3 -3
  69. data/docs/nunitAddins.html +41 -144
  70. data/docs/pairwise.html +114 -0
  71. data/docs/parameterizedTests.html +141 -0
  72. data/docs/pathConstraints.html +162 -0
  73. data/docs/platform.html +37 -9
  74. data/docs/pnunit.html +93 -0
  75. data/docs/projectEditor.html +82 -11
  76. data/docs/property.html +39 -10
  77. data/docs/propertyConstraint.html +12 -9
  78. data/docs/quickStart.html +9 -4
  79. data/docs/random.html +138 -0
  80. data/docs/range.html +149 -0
  81. data/docs/releaseDetail.html +861 -0
  82. data/docs/releaseNotes.html +457 -1133
  83. data/docs/repeat.html +104 -0
  84. data/docs/requiredAddin.html +153 -0
  85. data/docs/requiresMTA.html +152 -0
  86. data/docs/requiresSTA.html +153 -0
  87. data/docs/requiresThread.html +153 -0
  88. data/docs/sameasConstraint.html +23 -17
  89. data/docs/samples.html +12 -9
  90. data/docs/sequential.html +132 -0
  91. data/docs/setCulture.html +32 -9
  92. data/docs/{optionsDialog.html → settingsDialog.html} +89 -53
  93. data/docs/setup.html +61 -16
  94. data/docs/setupFixture.html +32 -9
  95. data/docs/stringAssert.html +15 -12
  96. data/docs/stringConstraints.html +12 -9
  97. data/docs/suite.html +32 -11
  98. data/docs/suiteBuilders.html +106 -0
  99. data/docs/teardown.html +56 -16
  100. data/docs/test.html +67 -18
  101. data/docs/testCase.html +168 -0
  102. data/docs/testCaseSource.html +284 -0
  103. data/docs/testDecorators.html +117 -0
  104. data/docs/testFixture.html +228 -16
  105. data/docs/testProperties.html +10 -5
  106. data/docs/testcaseBuilders.html +117 -0
  107. data/docs/testcaseProviders.html +122 -0
  108. data/docs/theory.html +208 -0
  109. data/docs/throwsConstraint.html +112 -0
  110. data/docs/timeout.html +109 -0
  111. data/docs/typeAsserts.html +47 -14
  112. data/docs/typeConstraints.html +12 -9
  113. data/docs/upgrade.html +23 -17
  114. data/docs/utilityAsserts.html +38 -16
  115. data/docs/valueSource.html +137 -0
  116. data/docs/values.html +136 -0
  117. data/docs/vsSupport.html +5 -6
  118. data/lib/net-1.1/NUnitTests.config +2 -2
  119. data/lib/net-1.1/NUnitTests.nunit +8 -11
  120. data/lib/net-1.1/agent.conf +4 -0
  121. data/lib/net-1.1/agent.log.conf +18 -0
  122. data/lib/net-1.1/framework/nunit.framework.dll +0 -0
  123. data/lib/net-1.1/framework/nunit.framework.xml +9321 -0
  124. data/lib/net-1.1/framework/nunit.mocks.dll +0 -0
  125. data/lib/net-1.1/framework/pnunit.framework.dll +0 -0
  126. data/lib/net-1.1/launcher.log.conf +18 -0
  127. data/lib/net-1.1/{fit.dll → lib/fit.dll} +0 -0
  128. data/lib/net-1.1/lib/log4net.dll +0 -0
  129. data/lib/net-1.1/lib/nunit-console-runner.dll +0 -0
  130. data/lib/net-1.1/lib/nunit.core.dll +0 -0
  131. data/lib/net-1.1/lib/nunit.core.interfaces.dll +0 -0
  132. data/lib/net-1.1/lib/nunit.fixtures.dll +0 -0
  133. data/lib/net-1.1/lib/nunit.util.dll +0 -0
  134. data/lib/net-1.1/nunit-agent.exe +0 -0
  135. data/lib/net-1.1/{nunit.exe.config → nunit-agent.exe.config} +21 -55
  136. data/lib/net-1.1/nunit-console.exe +0 -0
  137. data/lib/net-1.1/nunit-console.exe.config +19 -49
  138. data/lib/net-1.1/nunit.framework.dll +0 -0
  139. data/lib/net-1.1/pnunit-agent.exe +0 -0
  140. data/lib/net-1.1/pnunit-agent.exe.config +87 -0
  141. data/lib/net-1.1/pnunit-launcher.exe +0 -0
  142. data/lib/net-1.1/pnunit-launcher.exe.config +87 -0
  143. data/lib/net-1.1/pnunit.framework.dll +0 -0
  144. data/lib/net-1.1/pnunit.tests.dll +0 -0
  145. data/lib/net-1.1/runpnunit.bat +2 -0
  146. data/lib/net-1.1/test.conf +24 -0
  147. data/lib/net-1.1/{loadtest-assembly.dll → tests/loadtest-assembly.dll} +0 -0
  148. data/lib/net-1.1/tests/mock-assembly.dll +0 -0
  149. data/lib/net-1.1/tests/nonamespace-assembly.dll +0 -0
  150. data/lib/net-1.1/tests/nunit-console.tests.dll +0 -0
  151. data/lib/net-1.1/tests/nunit.core.tests.dll +0 -0
  152. data/lib/net-1.1/tests/nunit.fixtures.tests.dll +0 -0
  153. data/lib/net-1.1/tests/nunit.framework.dll +0 -0
  154. data/lib/net-1.1/tests/nunit.framework.tests.dll +0 -0
  155. data/lib/net-1.1/tests/nunit.mocks.tests.dll +0 -0
  156. data/lib/net-1.1/{nunit.util.tests.dll → tests/nunit.util.tests.dll} +0 -0
  157. data/lib/net-1.1/tests/test-assembly.dll +0 -0
  158. data/lib/net-1.1/tests/test-utilities.dll +0 -0
  159. data/lib/net-1.1/tests/timing-tests.dll +0 -0
  160. data/lib/net-2.0/NUnitTests.config +2 -2
  161. data/lib/net-2.0/NUnitTests.nunit +11 -11
  162. data/lib/net-2.0/agent.conf +4 -0
  163. data/lib/net-2.0/agent.log.conf +18 -0
  164. data/lib/net-2.0/framework/nunit.framework.dll +0 -0
  165. data/lib/net-2.0/framework/nunit.framework.xml +9803 -0
  166. data/lib/net-2.0/framework/nunit.mocks.dll +0 -0
  167. data/lib/net-2.0/framework/pnunit.framework.dll +0 -0
  168. data/lib/net-2.0/launcher.log.conf +18 -0
  169. data/lib/{net-1.1 → net-2.0/lib}/Failure.jpg +0 -0
  170. data/lib/net-2.0/{Success.jpg → lib/Gray.jpg} +0 -0
  171. data/lib/{net-1.1 → net-2.0/lib}/Ignored.jpg +0 -0
  172. data/lib/{net-1.1 → net-2.0/lib}/Success.jpg +0 -0
  173. data/lib/net-2.0/{fit.dll → lib/fit.dll} +0 -0
  174. data/lib/net-2.0/lib/log4net.dll +0 -0
  175. data/lib/net-2.0/lib/nunit-console-runner.dll +0 -0
  176. data/lib/net-2.0/lib/nunit-gui-runner.dll +0 -0
  177. data/lib/net-2.0/lib/nunit.core.dll +0 -0
  178. data/lib/net-2.0/lib/nunit.core.interfaces.dll +0 -0
  179. data/lib/net-2.0/lib/nunit.fixtures.dll +0 -0
  180. data/lib/net-2.0/lib/nunit.uiexception.dll +0 -0
  181. data/lib/net-2.0/lib/nunit.uikit.dll +0 -0
  182. data/lib/net-2.0/lib/nunit.util.dll +0 -0
  183. data/lib/net-2.0/nunit-agent.exe +0 -0
  184. data/lib/net-2.0/nunit-agent.exe.config +87 -0
  185. data/lib/net-2.0/nunit-console-x86.exe +0 -0
  186. data/lib/net-2.0/nunit-console-x86.exe.config +19 -49
  187. data/lib/net-2.0/nunit-console.exe +0 -0
  188. data/lib/net-2.0/nunit-console.exe.config +19 -49
  189. data/lib/net-2.0/nunit-x86.exe +0 -0
  190. data/lib/net-2.0/nunit-x86.exe.config +48 -74
  191. data/lib/net-2.0/nunit.exe +0 -0
  192. data/lib/net-2.0/nunit.exe.config +48 -74
  193. data/lib/net-2.0/nunit.framework.dll +0 -0
  194. data/lib/net-2.0/pnunit-agent.exe +0 -0
  195. data/lib/net-2.0/pnunit-agent.exe.config +87 -0
  196. data/lib/net-2.0/pnunit-launcher.exe +0 -0
  197. data/lib/net-2.0/pnunit-launcher.exe.config +87 -0
  198. data/lib/net-2.0/pnunit.framework.dll +0 -0
  199. data/lib/net-2.0/pnunit.tests.dll +0 -0
  200. data/lib/net-2.0/runpnunit.bat +2 -0
  201. data/lib/net-2.0/test.conf +24 -0
  202. data/lib/net-2.0/{loadtest-assembly.dll → tests/loadtest-assembly.dll} +0 -0
  203. data/lib/net-2.0/tests/mock-assembly.dll +0 -0
  204. data/lib/net-2.0/tests/nonamespace-assembly.dll +0 -0
  205. data/lib/net-2.0/tests/nunit-console.tests.dll +0 -0
  206. data/lib/net-2.0/tests/nunit-gui.tests.dll +0 -0
  207. data/lib/net-2.0/tests/nunit.core.tests.dll +0 -0
  208. data/lib/net-2.0/tests/nunit.fixtures.tests.dll +0 -0
  209. data/lib/net-2.0/tests/nunit.framework.dll +0 -0
  210. data/lib/net-2.0/tests/nunit.framework.tests.dll +0 -0
  211. data/lib/net-2.0/tests/nunit.mocks.tests.dll +0 -0
  212. data/lib/net-2.0/tests/nunit.uiexception.tests.dll +0 -0
  213. data/lib/net-2.0/tests/nunit.uikit.tests.dll +0 -0
  214. data/lib/net-2.0/{nunit.util.tests.dll → tests/nunit.util.tests.dll} +0 -0
  215. data/lib/net-2.0/tests/test-assembly.dll +0 -0
  216. data/lib/net-2.0/tests/test-utilities.dll +0 -0
  217. data/lib/net-2.0/tests/timing-tests.dll +0 -0
  218. metadata +131 -74
  219. data/docs/classicModel.html +0 -92
  220. data/docs/customAsserts.html +0 -115
  221. data/docs/features.html +0 -75
  222. data/docs/files/Thumbs.db +0 -0
  223. data/docs/platformSupport.html +0 -99
  224. data/lib/net-1.1/mock-assembly.dll +0 -0
  225. data/lib/net-1.1/nonamespace-assembly.dll +0 -0
  226. data/lib/net-1.1/notestfixtures-assembly.dll +0 -0
  227. data/lib/net-1.1/nunit-console-runner.dll +0 -0
  228. data/lib/net-1.1/nunit-console.tests.dll +0 -0
  229. data/lib/net-1.1/nunit-gui-runner.dll +0 -0
  230. data/lib/net-1.1/nunit-gui.tests.dll +0 -0
  231. data/lib/net-1.1/nunit.core.dll +0 -0
  232. data/lib/net-1.1/nunit.core.extensions.dll +0 -0
  233. data/lib/net-1.1/nunit.core.interfaces.dll +0 -0
  234. data/lib/net-1.1/nunit.core.tests.dll +0 -0
  235. data/lib/net-1.1/nunit.exe +0 -0
  236. data/lib/net-1.1/nunit.extensions.tests.dll +0 -0
  237. data/lib/net-1.1/nunit.fixtures.dll +0 -0
  238. data/lib/net-1.1/nunit.fixtures.tests.dll +0 -0
  239. data/lib/net-1.1/nunit.framework.extensions.dll +0 -0
  240. data/lib/net-1.1/nunit.framework.tests.dll +0 -0
  241. data/lib/net-1.1/nunit.framework.xml +0 -5622
  242. data/lib/net-1.1/nunit.mocks.dll +0 -0
  243. data/lib/net-1.1/nunit.mocks.tests.dll +0 -0
  244. data/lib/net-1.1/nunit.uikit.dll +0 -0
  245. data/lib/net-1.1/nunit.uikit.tests.dll +0 -0
  246. data/lib/net-1.1/nunit.util.dll +0 -0
  247. data/lib/net-1.1/test-assembly.dll +0 -0
  248. data/lib/net-1.1/test-utilities.dll +0 -0
  249. data/lib/net-1.1/timing-tests.dll +0 -0
  250. data/lib/net-2.0/Failure.jpg +0 -0
  251. data/lib/net-2.0/Ignored.jpg +0 -0
  252. data/lib/net-2.0/mock-assembly.dll +0 -0
  253. data/lib/net-2.0/nonamespace-assembly.dll +0 -0
  254. data/lib/net-2.0/notestfixtures-assembly.dll +0 -0
  255. data/lib/net-2.0/nunit-console-runner.dll +0 -0
  256. data/lib/net-2.0/nunit-console.tests.dll +0 -0
  257. data/lib/net-2.0/nunit-gui-runner.dll +0 -0
  258. data/lib/net-2.0/nunit-gui.tests.dll +0 -0
  259. data/lib/net-2.0/nunit.core.dll +0 -0
  260. data/lib/net-2.0/nunit.core.extensions.dll +0 -0
  261. data/lib/net-2.0/nunit.core.interfaces.dll +0 -0
  262. data/lib/net-2.0/nunit.core.tests.dll +0 -0
  263. data/lib/net-2.0/nunit.extensions.tests.dll +0 -0
  264. data/lib/net-2.0/nunit.fixtures.dll +0 -0
  265. data/lib/net-2.0/nunit.fixtures.tests.dll +0 -0
  266. data/lib/net-2.0/nunit.framework.extensions.dll +0 -0
  267. data/lib/net-2.0/nunit.framework.tests.dll +0 -0
  268. data/lib/net-2.0/nunit.framework.xml +0 -5622
  269. data/lib/net-2.0/nunit.mocks.dll +0 -0
  270. data/lib/net-2.0/nunit.mocks.tests.dll +0 -0
  271. data/lib/net-2.0/nunit.uikit.dll +0 -0
  272. data/lib/net-2.0/nunit.uikit.tests.dll +0 -0
  273. data/lib/net-2.0/nunit.util.dll +0 -0
  274. data/lib/net-2.0/test-assembly.dll +0 -0
  275. data/lib/net-2.0/test-utilities.dll +0 -0
  276. data/lib/net-2.0/timing-tests.dll +0 -0
@@ -1,4 +1,4 @@
1
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
1
+ <!-- saved from url=(0014)about:internet --><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
2
2
  <html>
3
3
  <!-- Standard Head Part -->
4
4
  <head>
@@ -29,18 +29,44 @@
29
29
  <p>The Addins Dialog is displayed using the Tools | Addins menu item on the main
30
30
  menu. It lists all addins that have been found and loaded by NUnit.</p>
31
31
 
32
- <div class="screenshot-left">
32
+ <div class="screenshot-right">
33
33
  <img src="img/addinsDialog.jpg"></div>
34
34
 
35
+ <h3>Addin</h3>
36
+
37
+ <p>This column lists the name of the addin, as defined by its author.
38
+
39
+ <h3>Status</h3>
40
+
41
+ <p>This column shows the status of each addin. Possible values are
42
+ <ul>
43
+ <li>Unknown
44
+ <li>Enabled
45
+ <li>Disabled
46
+ <li>Loaded
47
+ <li>Error
48
+ </ul>
49
+
50
+ <h3>Description</h3>
51
+
52
+ <p>If the author of an addin has provided a description, it is
53
+ shown here when the addin is selected.
54
+
55
+ <h3>Message</h3>
56
+
57
+ <p>If the addin failed to load, its status will be shown as Error
58
+ and any error message displayed here when that addin is selected.
59
+
35
60
  </div>
36
61
 
37
62
  <!-- Submenu -->
38
63
  <div id="subnav">
39
64
  <ul>
40
- <li><a href="index.html">NUnit 2.4.8</a></li>
65
+ <li><a href="index.html">NUnit 2.5</a></li>
41
66
  <ul>
42
67
  <li><a href="getStarted.html">Getting&nbsp;Started</a></li>
43
68
  <li><a href="assertions.html">Assertions</a></li>
69
+ <li><a href="constraintModel.html">Constraints</a></li>
44
70
  <li><a href="attributes.html">Attributes</a></li>
45
71
  <li><a href="nunit-console.html">Console&nbsp;Runner</a></li>
46
72
  <li><a href="nunit-gui.html">Gui&nbsp;Runner</a></li>
@@ -48,13 +74,17 @@ menu. It lists all addins that have been found and loaded by NUnit.</p>
48
74
  <li><a href="guiCommandLine.html">Command-Line</a></li>
49
75
  <li><a href="mainMenu.html">Main&nbsp;Menu</a></li>
50
76
  <li><a href="contextMenu.html">Context&nbsp;Menu</a></li>
51
- <li><a href="optionsDialog.html">Options&nbsp;Dialog</a></li>
77
+ <li><a href="settingsDialog.html">Settings&nbsp;Dialog</a></li>
52
78
  <li id="current"><a href="addinsDialog.html">Addins&nbsp;Dialog</a></li>
53
79
  <li><a href="testProperties.html">Test&nbsp;Properties</a></li>
54
80
  <li><a href="configEditor.html">Configuration&nbsp;Editor</a></li>
55
81
  <li><a href="projectEditor.html">Project&nbsp;Editor</a></li>
56
82
  </ul>
57
- <li><a href="features.html">Other&nbsp;Features</a></li>
83
+ <li><a href="configFiles.html">Configuration&nbsp;Files</a></li>
84
+ <li><a href="pnunit.html">PNUnit</a></li>
85
+ <li><a href="multiAssembly.html">Multiple&nbsp;Assemblies</a></li>
86
+ <li><a href="vsSupport.html">Visual&nbsp;Studio&nbsp;Support</a></li>
87
+ <li><a href="extensibility.html">Extensibility</a></li>
58
88
  <li><a href="releaseNotes.html">Release&nbsp;Notes</a></li>
59
89
  <li><a href="samples.html">Samples</a></li>
60
90
  <li><a href="license.html">License</a></li>
@@ -66,7 +96,7 @@ menu. It lists all addins that have been found and loaded by NUnit.</p>
66
96
 
67
97
  <!-- Standard Footer for NUnit.org -->
68
98
  <div id="footer">
69
- Copyright &copy; 2008 Charlie Poole. All Rights Reserved.
99
+ Copyright &copy; 2009 Charlie Poole. All Rights Reserved.
70
100
  </div>
71
101
  <!-- End of Footer -->
72
102
 
@@ -1,4 +1,4 @@
1
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
1
+ <!-- saved from url=(0014)about:internet --><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
2
2
  <html>
3
3
  <!-- Standard Head Part -->
4
4
  <head>
@@ -42,36 +42,55 @@
42
42
  <h3>Two Models</h3>
43
43
 
44
44
  <p>Before NUnit 2.4, a separate method of the Assert class was used for each
45
- different assertion. We call this the
46
- <a href="classicModel.html">classic model</a>. It
45
+ different assertion. We call this the "Classic Model." It
47
46
  continues to be supported in NUnit, since many people prefer it.</p>
48
47
 
49
- <p>Beginning with NUnit 2.4, a new
50
- <a href="constraintModel.html">constraint-based model</a> is being
48
+ <p>Beginning with NUnit 2.4, a new "Constraint-based" model was
51
49
  introduced. This approach uses a single method of the Assert class
52
- for all assertions, passing a <b>constraint</b> object that specifies the
53
- test to be performed.
50
+ for all assertions, passing a <a href="constraintModel.html">Constraint</a> object that specifies the test to be performed.
54
51
 
55
52
  <p>This constraint-based model is now used internally by NUnit
56
53
  for all assertions. The methods of the classic approach have been
57
54
  re-implemented on top of this new model.
55
+
56
+ <!--
57
+ <h4>See Also...</h4>
58
+ <ul>
59
+ <li>
60
+ </ul>
61
+ -->
62
+
58
63
  </div>
59
64
 
60
65
  <!-- Submenu -->
61
66
  <div id="subnav">
62
67
  <ul>
63
- <li><a href="index.html">NUnit 2.4.8</a></li>
68
+ <li><a href="index.html">NUnit 2.5</a></li>
64
69
  <ul>
65
70
  <li><a href="getStarted.html">Getting&nbsp;Started</a></li>
66
71
  <li id="current"><a href="assertions.html">Assertions</a></li>
67
72
  <ul>
68
- <li><a href="classicModel.html">Classic&nbsp;Model</a></li>
69
- <li><a href="constraintModel.html">Constraint&nbsp;Model</a></li>
73
+ <li><a href="equalityAsserts.html">Equality&nbsp;Asserts</a></li>
74
+ <li><a href="identityAsserts.html">Identity&nbsp;Asserts</a></li>
75
+ <li><a href="conditionAsserts.html">Condition&nbsp;Asserts</a></li>
76
+ <li><a href="comparisonAsserts.html">Comparison&nbsp;Asserts</a></li>
77
+ <li><a href="typeAsserts.html">Type&nbsp;Asserts</a></li>
78
+ <li><a href="exceptionAsserts.html">Exception&nbsp;Asserts</a></li>
79
+ <li><a href="utilityAsserts.html">Utility&nbsp;Methods</a></li>
80
+ <li><a href="stringAssert.html">String&nbsp;Assert</a></li>
81
+ <li><a href="collectionAssert.html">Collection&nbsp;Assert</a></li>
82
+ <li><a href="fileAssert.html">File&nbsp;Assert</a></li>
83
+ <li><a href="directoryAssert.html">Directory&nbsp;Assert</a></li>
70
84
  </ul>
85
+ <li><a href="constraintModel.html">Constraints</a></li>
71
86
  <li><a href="attributes.html">Attributes</a></li>
72
87
  <li><a href="nunit-console.html">Console&nbsp;Runner</a></li>
73
88
  <li><a href="nunit-gui.html">Gui&nbsp;Runner</a></li>
74
- <li><a href="features.html">Other&nbsp;Features</a></li>
89
+ <li><a href="configFiles.html">Configuration&nbsp;Files</a></li>
90
+ <li><a href="pnunit.html">PNUnit</a></li>
91
+ <li><a href="multiAssembly.html">Multiple&nbsp;Assemblies</a></li>
92
+ <li><a href="vsSupport.html">Visual&nbsp;Studio&nbsp;Support</a></li>
93
+ <li><a href="extensibility.html">Extensibility</a></li>
75
94
  <li><a href="releaseNotes.html">Release&nbsp;Notes</a></li>
76
95
  <li><a href="samples.html">Samples</a></li>
77
96
  <li><a href="license.html">License</a></li>
@@ -83,7 +102,7 @@
83
102
 
84
103
  <!-- Standard Footer for NUnit.org -->
85
104
  <div id="footer">
86
- Copyright &copy; 2008 Charlie Poole. All Rights Reserved.
105
+ Copyright &copy; 2009 Charlie Poole. All Rights Reserved.
87
106
  </div>
88
107
  <!-- End of Footer -->
89
108
 
@@ -1,4 +1,4 @@
1
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
1
+ <!-- saved from url=(0014)about:internet --><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
2
2
  <html>
3
3
  <!-- Standard Head Part -->
4
4
  <head>
@@ -37,51 +37,74 @@
37
37
  the project must reference the framework assembly, nunit.framework.dll.</p>
38
38
  <p>Beginning with NUnit 2.4.6, NUnit's attributes are no longer sealed and any
39
39
  attributes that derive from them will be recogized by NUnit.
40
-
40
+
41
41
  </div>
42
42
 
43
43
  <!-- Submenu -->
44
44
  <div id="subnav">
45
- <ul>
46
- <li><a href="index.html">NUnit 2.4.8</a></li>
47
- <ul>
48
- <li><a href="getStarted.html">Getting&nbsp;Started</a></li>
49
- <li><a href="assertions.html">Assertions</a></li>
50
- <li id="current"><a href="attributes.html">Attributes</a></li>
51
- <ul>
52
- <li><a href="category.html">Category</a></li>
53
- <li><a href="culture.html">Culture</a></li>
54
- <li><a href="description.html">Description</a></li>
55
- <li><a href="exception.html">Expected&nbsp;Exception</a></li>
56
- <li><a href="explicit.html">Explicit</a></li>
57
- <li><a href="ignore.html">Ignore</a></li>
58
- <li><a href="platform.html">Platform</a></li>
59
- <li><a href="property.html">Property</a></li>
60
- <li><a href="setCulture.html">SetCulture</a></li>
61
- <li><a href="setup.html">Setup</a></li>
62
- <li><a href="setupFixture.html">SetUp&nbsp;Fixture</a></li>
63
- <li><a href="suite.html">Suite</a></li>
64
- <li><a href="teardown.html">Teardown</a></li>
65
- <li><a href="test.html">Test</a></li>
66
- <li><a href="testFixture.html">Test&nbsp;Fixture</a></li>
67
- <li><a href="fixtureSetup.html">Test&nbsp;Fixture&nbsp;SetUp</a></li>
68
- <li><a href="fixtureTeardown.html">Test&nbsp;Fixture&nbsp;TearDown</a></li>
69
- </ul>
70
- <li><a href="nunit-console.html">Console&nbsp;Runner</a></li>
71
- <li><a href="nunit-gui.html">Gui&nbsp;Runner</a></li>
72
- <li><a href="features.html">Other&nbsp;Features</a></li>
73
- <li><a href="releaseNotes.html">Release&nbsp;Notes</a></li>
74
- <li><a href="samples.html">Samples</a></li>
75
- <li><a href="license.html">License</a></li>
76
- </ul>
77
- </ul>
45
+ <ul>
46
+ <li><a href="index.html">NUnit 2.5</a></li>
47
+ <ul>
48
+ <li><a href="getStarted.html">Getting&nbsp;Started</a></li>
49
+ <li><a href="assertions.html">Assertions</a></li>
50
+ <li><a href="constraintModel.html">Constraints</a></li>
51
+ <li id="current"><a href="attributes.html">Attributes</a></li>
52
+ <ul>
53
+ <li><a href="category.html">Category</a></li>
54
+ <li><a href="combinatorial.html">Combinatorial</a></li>
55
+ <li><a href="culture.html">Culture</a></li>
56
+ <li><a href="datapoint.html">Datapoint(s)</a></li>
57
+ <li><a href="description.html">Description</a></li>
58
+ <li><a href="exception.html">Exception</a></li>
59
+ <li><a href="explicit.html">Explicit</a></li>
60
+ <li><a href="ignore.html">Ignore</a></li>
61
+ <li><a href="maxtime.html">Maxtime</a></li>
62
+ <li><a href="pairwise.html">Pairwise</a></li>
63
+ <li><a href="platform.html">Platform</a></li>
64
+ <li><a href="property.html">Property</a></li>
65
+ <li><a href="random.html">Random</a></li>
66
+ <li><a href="range.html">Range</a></li>
67
+ <li><a href="repeat.html">Repeat</a></li>
68
+ <li><a href="requiredAddin.html">RequiredAddin</a></li>
69
+ <li><a href="requiresMTA.html">Requires&nbsp;MTA</a></li>
70
+ <li><a href="requiresSTA.html">Requires&nbsp;STA</a></li>
71
+ <li><a href="requiresThread.html">Requires&nbsp;Thread</a></li>
72
+ <li><a href="sequential.html">Sequential</a></li>
73
+ <li><a href="setCulture.html">SetCulture</a></li>
74
+ <li><a href="setup.html">Setup</a></li>
75
+ <li><a href="setupFixture.html">SetupFixture</a></li>
76
+ <li><a href="suite.html">Suite</a></li>
77
+ <li><a href="teardown.html">Teardown</a></li>
78
+ <li><a href="test.html">Test</a></li>
79
+ <li><a href="testCase.html">TestCase</a></li>
80
+ <li><a href="testCaseSource.html">TestCaseSource</a></li>
81
+ <li><a href="testFixture.html">TestFixture</a></li>
82
+ <li><a href="fixtureSetup.html">TestFixtureSetUp</a></li>
83
+ <li><a href="fixtureTeardown.html">TestFixtureTearDown</a></li>
84
+ <li><a href="theory.html">Theory</a></li>
85
+ <li><a href="timeout.html">Timeout</a></li>
86
+ <li><a href="values.html">Values</a></li>
87
+ <li><a href="valueSource.html">ValueSource</a></li>
88
+ </ul>
89
+ <li><a href="nunit-console.html">Console&nbsp;Runner</a></li>
90
+ <li><a href="nunit-gui.html">Gui&nbsp;Runner</a></li>
91
+ <li><a href="configFiles.html">Configuration&nbsp;Files</a></li>
92
+ <li><a href="pnunit.html">PNUnit</a></li>
93
+ <li><a href="multiAssembly.html">Multiple&nbsp;Assemblies</a></li>
94
+ <li><a href="vsSupport.html">Visual&nbsp;Studio&nbsp;Support</a></li>
95
+ <li><a href="extensibility.html">Extensibility</a></li>
96
+ <li><a href="releaseNotes.html">Release&nbsp;Notes</a></li>
97
+ <li><a href="samples.html">Samples</a></li>
98
+ <li><a href="license.html">License</a></li>
99
+ </ul>
100
+ </ul>
78
101
  </div>
79
102
  <!-- End of Submenu -->
80
103
 
81
104
 
82
105
  <!-- Standard Footer for NUnit.org -->
83
106
  <div id="footer">
84
- Copyright &copy; 2008 Charlie Poole. All Rights Reserved.
107
+ Copyright &copy; 2009 Charlie Poole. All Rights Reserved.
85
108
  </div>
86
109
  <!-- End of Footer -->
87
110
 
@@ -1,4 +1,4 @@
1
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
1
+ <!-- saved from url=(0014)about:internet --><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
2
2
  <html>
3
3
  <!-- Standard Head Part -->
4
4
  <head>
@@ -219,33 +219,56 @@ public void MyTest()
219
219
  <!-- Submenu -->
220
220
  <div id="subnav">
221
221
  <ul>
222
- <li><a href="index.html">NUnit 2.4.8</a></li>
222
+ <li><a href="index.html">NUnit 2.5</a></li>
223
223
  <ul>
224
224
  <li><a href="getStarted.html">Getting&nbsp;Started</a></li>
225
225
  <li><a href="assertions.html">Assertions</a></li>
226
+ <li><a href="constraintModel.html">Constraints</a></li>
226
227
  <li><a href="attributes.html">Attributes</a></li>
227
228
  <ul>
228
229
  <li id="current"><a href="category.html">Category</a></li>
230
+ <li><a href="combinatorial.html">Combinatorial</a></li>
229
231
  <li><a href="culture.html">Culture</a></li>
232
+ <li><a href="datapoint.html">Datapoint(s)</a></li>
230
233
  <li><a href="description.html">Description</a></li>
231
- <li><a href="exception.html">Expected&nbsp;Exception</a></li>
234
+ <li><a href="exception.html">Exception</a></li>
232
235
  <li><a href="explicit.html">Explicit</a></li>
233
236
  <li><a href="ignore.html">Ignore</a></li>
237
+ <li><a href="maxtime.html">Maxtime</a></li>
238
+ <li><a href="pairwise.html">Pairwise</a></li>
234
239
  <li><a href="platform.html">Platform</a></li>
235
240
  <li><a href="property.html">Property</a></li>
241
+ <li><a href="random.html">Random</a></li>
242
+ <li><a href="range.html">Range</a></li>
243
+ <li><a href="repeat.html">Repeat</a></li>
244
+ <li><a href="requiredAddin.html">RequiredAddin</a></li>
245
+ <li><a href="requiresMTA.html">Requires&nbsp;MTA</a></li>
246
+ <li><a href="requiresSTA.html">Requires&nbsp;STA</a></li>
247
+ <li><a href="requiresThread.html">Requires&nbsp;Thread</a></li>
248
+ <li><a href="sequential.html">Sequential</a></li>
236
249
  <li><a href="setCulture.html">SetCulture</a></li>
237
250
  <li><a href="setup.html">Setup</a></li>
238
- <li><a href="setupFixture.html">SetUp&nbsp;Fixture</a></li>
251
+ <li><a href="setupFixture.html">SetupFixture</a></li>
239
252
  <li><a href="suite.html">Suite</a></li>
240
253
  <li><a href="teardown.html">Teardown</a></li>
241
254
  <li><a href="test.html">Test</a></li>
242
- <li><a href="testFixture.html">Test&nbsp;Fixture</a></li>
243
- <li><a href="fixtureSetup.html">Test&nbsp;Fixture&nbsp;SetUp</a></li>
244
- <li><a href="fixtureTeardown.html">Test&nbsp;Fixture&nbsp;TearDown</a></li>
255
+ <li><a href="testCase.html">TestCase</a></li>
256
+ <li><a href="testCaseSource.html">TestCaseSource</a></li>
257
+ <li><a href="testFixture.html">TestFixture</a></li>
258
+ <li><a href="fixtureSetup.html">TestFixtureSetUp</a></li>
259
+ <li><a href="fixtureTeardown.html">TestFixtureTearDown</a></li>
260
+ <li><a href="theory.html">Theory</a></li>
261
+ <li><a href="timeout.html">Timeout</a></li>
262
+ <li><a href="values.html">Values</a></li>
263
+ <li><a href="valueSource.html">ValueSource</a></li>
245
264
  </ul>
246
265
  <li><a href="nunit-console.html">Console&nbsp;Runner</a></li>
247
266
  <li><a href="nunit-gui.html">Gui&nbsp;Runner</a></li>
248
- <li><a href="features.html">Other&nbsp;Features</a></li>
267
+ <li><a href="configFiles.html">Configuration&nbsp;Files</a></li>
268
+ <li><a href="pnunit.html">PNUnit</a></li>
269
+ <li><a href="multiAssembly.html">Multiple&nbsp;Assemblies</a></li>
270
+ <li><a href="vsSupport.html">Visual&nbsp;Studio&nbsp;Support</a></li>
271
+ <li><a href="extensibility.html">Extensibility</a></li>
249
272
  <li><a href="releaseNotes.html">Release&nbsp;Notes</a></li>
250
273
  <li><a href="samples.html">Samples</a></li>
251
274
  <li><a href="license.html">License</a></li>
@@ -257,7 +280,7 @@ public void MyTest()
257
280
 
258
281
  <!-- Standard Footer for NUnit.org -->
259
282
  <div id="footer">
260
- Copyright &copy; 2008 Charlie Poole. All Rights Reserved.
283
+ Copyright &copy; 2009 Charlie Poole. All Rights Reserved.
261
284
  </div>
262
285
  <!-- End of Footer -->
263
286
 
@@ -1,4 +1,4 @@
1
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
1
+ <!-- saved from url=(0014)about:internet --><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
2
2
  <html>
3
3
  <!-- Standard Head Part -->
4
4
  <head>
@@ -24,7 +24,7 @@
24
24
 
25
25
  <div id="content">
26
26
 
27
- <h2>CollectionAssert (NUnit 2.4)</h2>
27
+ <h2>CollectionAssert (NUnit 2.4 / 2.5)</h2>
28
28
  <p>The CollectionAssert class provides a number of methods that are useful
29
29
  when examining collections and their contents or for comparing two collections.</p>
30
30
 
@@ -112,37 +112,55 @@ CollectionAssert.IsEmpty( IEnumerable collection, string message,
112
112
  CollectionAssert.IsNotEmpty( IEnumerable collection );
113
113
  CollectionAssert.IsNotEmpty( IEnumerable collection, string message );
114
114
  CollectionAssert.IsNotEmpty( IEnumerable collection, string message,
115
- params object[] args );</pre>
116
- </div>
115
+ params object[] args );
116
+ </pre></div>
117
+
118
+ <p>The following methods are available beginning with NUnit 2.5
119
+
120
+ <div class="code" style="width: 38em"><pre>
121
+ CollectionAssert.IsOrdered( IEnumerable collection );
122
+ CollectionAssert.IsOrdered( IEnumerable collection, string message );
123
+ CollectionAssert.IsOrdered( IEnumerable collection, string message,
124
+ params object[] args );
125
+
126
+ CollectionAssert.IsOrdered( IEnumerable collection, IComparer comparer );
127
+ CollectionAssert.IsOrdered( IEnumerable collection, IComparer comparer,
128
+ string message );
129
+ CollectionAssert.IsOrdered( IEnumerable collection, IComparer comparer,
130
+ string message, params object[] args );
131
+ </pre></div>
117
132
 
118
133
  </div>
119
134
 
120
135
  <!-- Submenu -->
121
136
  <div id="subnav">
122
137
  <ul>
123
- <li><a href="index.html">NUnit 2.4.8</a></li>
138
+ <li><a href="index.html">NUnit 2.5</a></li>
124
139
  <ul>
125
140
  <li><a href="getStarted.html">Getting&nbsp;Started</a></li>
126
141
  <li><a href="assertions.html">Assertions</a></li>
127
142
  <ul>
128
- <li><a href="classicModel.html">Classic&nbsp;Model</a></li>
129
- <ul>
130
143
  <li><a href="equalityAsserts.html">Equality&nbsp;Asserts</a></li>
131
144
  <li><a href="identityAsserts.html">Identity&nbsp;Asserts</a></li>
132
- <li><a href="conditionAsserts.html">Condition&nbsp;Tests</a></li>
145
+ <li><a href="conditionAsserts.html">Condition&nbsp;Asserts</a></li>
133
146
  <li><a href="comparisonAsserts.html">Comparison&nbsp;Asserts</a></li>
134
147
  <li><a href="typeAsserts.html">Type&nbsp;Asserts</a></li>
148
+ <li><a href="exceptionAsserts.html">Exception&nbsp;Asserts</a></li>
135
149
  <li><a href="utilityAsserts.html">Utility&nbsp;Methods</a></li>
136
150
  <li><a href="stringAssert.html">String&nbsp;Assert</a></li>
137
151
  <li id="current"><a href="collectionAssert.html">Collection&nbsp;Assert</a></li>
138
152
  <li><a href="fileAssert.html">File&nbsp;Assert</a></li>
153
+ <li><a href="directoryAssert.html">Directory&nbsp;Assert</a></li>
139
154
  </ul>
140
- <li><a href="constraintModel.html">Constraint&nbsp;Model</a></li>
141
- </ul>
155
+ <li><a href="constraintModel.html">Constraints</a></li>
142
156
  <li><a href="attributes.html">Attributes</a></li>
143
157
  <li><a href="nunit-console.html">Console&nbsp;Runner</a></li>
144
158
  <li><a href="nunit-gui.html">Gui&nbsp;Runner</a></li>
145
- <li><a href="features.html">Other&nbsp;Features</a></li>
159
+ <li><a href="configFiles.html">Configuration&nbsp;Files</a></li>
160
+ <li><a href="pnunit.html">PNUnit</a></li>
161
+ <li><a href="multiAssembly.html">Multiple&nbsp;Assemblies</a></li>
162
+ <li><a href="vsSupport.html">Visual&nbsp;Studio&nbsp;Support</a></li>
163
+ <li><a href="extensibility.html">Extensibility</a></li>
146
164
  <li><a href="releaseNotes.html">Release&nbsp;Notes</a></li>
147
165
  <li><a href="samples.html">Samples</a></li>
148
166
  <li><a href="license.html">License</a></li>
@@ -154,7 +172,7 @@ CollectionAssert.IsNotEmpty( IEnumerable collection, string message,
154
172
 
155
173
  <!-- Standard Footer for NUnit.org -->
156
174
  <div id="footer">
157
- Copyright &copy; 2008 Charlie Poole. All Rights Reserved.
175
+ Copyright &copy; 2009 Charlie Poole. All Rights Reserved.
158
176
  </div>
159
177
  <!-- End of Footer -->
160
178
 
@@ -1,4 +1,4 @@
1
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
1
+ <!-- saved from url=(0014)about:internet --><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
2
2
  <html>
3
3
  <!-- Standard Head Part -->
4
4
  <head>
@@ -24,93 +24,291 @@
24
24
 
25
25
  <div id="content">
26
26
 
27
- <h2>Collection Constraints (NUnit 2.4)</h2>
27
+ <h2>Collection Constraints (NUnit 2.4 / 2.5)</h2>
28
28
 
29
29
  <p>Collection constraints perform tests that are specific to collections.
30
- The following collection constraints are provided.
30
+ The following collection constraints are provided. Before NUnit 2.4.6,
31
+ these constraints only operated on true Collections. Beginning with 2.4.6,
32
+ they can work with any object that implements IEnumerable.
31
33
 
32
- <table class="constraints">
33
- <tr><th>Syntax Helper</th><th>Constructor</th><th>Operation</th></tr>
34
- <tr><td>Is.All...<br>Has.All...</td><td>AllItemsConstraint( Constraint )</td></td><td>applies a constraint to each item in a collection, succeeding only if all of them succeed</td></tr>
35
- <tr><td>Has.Some...</td><td>SomeItemsConstraint( Constraint )</td></td><td>applies a constraint to each item in a collection, succeeding if at least one of them succeeds</td></tr>
36
- <tr><td>Has.None...</td><td>NoItemConstraint( Constraint )</td></td><td>applies a constraint to each item in a collection, succeeding only if all of them fail</td></tr>
37
- <tr><td>Is.Unique</td><td>UniqueItemsConstraint()</td></td><td>tests that a collection contains only unique items</td></tr>
38
- <tr><td>Has.Member( object )</td><td>CollectionContainsConstraint( object )</td></td><td>tests that a collection contains an object</td></tr>
39
- <tr><td>Is.EquivalentTo( IEnumerable )</td><td>CollectionEquivalentConstraint( ICollection )</td></td><td>tests that two collections are equivalent</td></tr>
40
- <tr><td>Is.SubsetOf( IEnumerable )</td><td>CollectionSubsetConstraint( ICollection )</td></td><td>tests that one collection is a subset of another</td></tr>
41
- </table>
34
+ <p>Beginning with NUnit 2.4.2, use of an improper argument type caused tests
35
+ to fail. Later releases give an error rather than a failure, so that negated
36
+ constraints will not appear to succeed.
37
+
38
+ <p>For example, both of the following statements give an error in later releases,
39
+ but the second would have succeeded in earlier versions of NUnit.
40
+
41
+ <div class="code"><pre>
42
+ int[] iarray = new int[] { 1, 2, 3 };
42
43
 
43
- <h4>Notes</h4>
44
+ Assert.That( 5, Is.SubsetOf( iarray ) ); // Fails in early releases
45
+ Assert.That( 5, Is.Not.SubsetOf( iarray ) ); /
46
+ </pre></div>
44
47
 
45
- <ol>
46
- <li>Two collections are equivalent if they contain the same items, in any order.
47
- <li>To compare collections for equality, use Is.EqualTo().
48
- <li>Has.Member uses object equality to find an object in a collection. To check
49
- for an object equal to an item the collection, use Has.Some.EqualTo().
50
- <li>Beginning with NUnit 2.4.2, use of a collection constraint with a non-collection
51
- argument causes an error rather than a test failure. This avoids false positives
52
- when the collection constraint is negated.
53
- <li>Beginning with NUnit 2.4.6, you may use any object implementing IEnumerable
54
- in place of a collection.
55
- </ol>
48
+ <h3>AllItemsConstraint</h3>
56
49
 
57
- <h4>Examples of Use</h4>
50
+ <h4>Action</h4>
51
+ <p>Applies a constraint to each item in a collection, succeeding only if all of them succeed.
52
+
53
+ <h4>Constructor</h4>
54
+ <div class="code"><pre>
55
+ AllItemsConstraint(Constraint itemConstraint)
56
+ </pre></div>
58
57
 
59
- <div class="code" style="width: 38em"><pre>
58
+ <h4>Syntax</h4>
59
+ <div class="code"><pre>
60
+ Is.All...
61
+ Has.All...
62
+ </pre></div>
63
+
64
+ <h4>Examples of Use</h4>
65
+ <div class="code"><pre>
60
66
  int[] iarray = new int[] { 1, 2, 3 };
61
67
  string[] sarray = new string[] { "a", "b", "c" };
62
68
 
63
69
  Assert.That( iarray, Is.All.Not.Null );
64
- Assert.That( sarray, Is.All.InstanceOfType(typeof(string)) );
70
+ Assert.That( sarray, Is.All.InstanceOf<string>() );
65
71
  Assert.That( iarray, Is.All.GreaterThan(0) );
66
-
72
+ Assert.That( iarray, Has.All.GreaterThan(0) );
73
+ </pre></div>
74
+
75
+ <h3>SomeItemsConstraint</h3>
76
+
77
+ <h4>Action</h4>
78
+ <p>Applies a constraint to each item in a collection, succeeding if at least one of them succeeds.
79
+
80
+ <h4>Constructor</h4>
81
+ <div class="code"><pre>
82
+ SomeItemsConstraint(Constraint itemConstraint)
83
+ </pre></div>
84
+
85
+ <h4>Syntax</h4>
86
+ <div class="code"><pre>
87
+ Has.Some...
88
+ </pre></div>
89
+
90
+ <h4>Examples of Use</h4>
91
+ <div class="code"><pre>
92
+ int[] iarray = new int[] { 1, 2, 3 };
93
+ string[] sarray = new string[] { "a", "b", "c" };
94
+
95
+ Assert.That( iarray, Has.Some.GreaterThan(2) );
96
+ Assert.That( sarray, Has.Some.Length(1) );
97
+ </pre></div>
98
+
99
+ <h3>NoItemConstraint</h3>
100
+
101
+ <h4>Action</h4>
102
+ <p>Applies a constraint to each item in a collection, succeeding only if all of them fail.
103
+
104
+ <h4>Constructor</h4>
105
+ <div class="code"><pre>
106
+ NoItemConstraint(Constraint itemConstraint)
107
+ </pre></div>
108
+
109
+ <h4>Syntax</h4>
110
+ <div class="code"><pre>
111
+ Has.None...
112
+ Has.No...
113
+ </pre></div>
114
+
115
+ <h4>Examples of Use</h4>
116
+ <div class="code"><pre>
117
+ int[] iarray = new int[] { 1, 2, 3 };
118
+ string[] sarray = new string[] { "a", "b", "c" };
119
+
120
+ Assert.That( iarray, Has.None.Null );
121
+ Assert.That( iarray, Has.No.Null );
122
+ Assert.That( sarray, Has.None.EqualTo("d") );
123
+ Assert.That( iarray, Has.None.LessThan(0) );
124
+ </pre></div>
125
+
126
+ <h3>UniqueItemsConstraint</h3>
127
+
128
+ <h4>Action</h4>
129
+ <p>Tests that a collection contains only unique items.
130
+
131
+ <h4>Constructor</h4>
132
+ <div class="code"><pre>
133
+ UniqueItemsConstraint()
134
+ </pre></div>
135
+
136
+ <h4>Syntax</h4>
137
+ <div class="code"><pre>
138
+ Is.Unique
139
+ </pre></div>
140
+
141
+ <h4>Example of Use</h4>
142
+ <div class="code"><pre>
143
+ string[] sarray = new string[] { "a", "b", "c" };
144
+
67
145
  Assert.That( sarray, Is.Unique );
146
+ </pre></div>
147
+
148
+ <h4>Notes</h4>
149
+ <ol>
150
+ <li>??
151
+ </ol>
152
+
153
+ <h3>CollectionContainsConstraint</h3>
154
+
155
+ <h4>Action</h4>
156
+ <p>Tests that a collection contains an object.
68
157
 
69
- Assert.That( iarray, List.Contains(3) );
70
- Assert.That( sarray, List.Contains("b") );
71
- Assert.That( sarray, List.Not.Contains("x") );
158
+ <h4>Constructor</h4>
159
+ <div class="code"><pre>
160
+ CollectionContainsConstraint( object )
161
+ </pre></div>
162
+
163
+ <h4>Syntax</h4>
164
+ <div class="code"><pre>
165
+ Has.Member( object )
166
+ </pre></div>
167
+
168
+ <h4>Examples of Use</h4>
169
+ <div class="code"><pre>
170
+ int[] iarray = new int[] { 1, 2, 3 };
171
+ string[] sarray = new string[] { "a", "b", "c" };
172
+
173
+ Assert.That( iarray, Has.Member(3) );
174
+ Assert.That( sarray, Has.Member("b") );
175
+ Assert.That( sarray, Has.No.Member("x") );
176
+ </pre></div>
177
+
178
+ <h4>Notes</h4>
179
+ <ol>
180
+ <li>For references, <b>Has.Member</b> uses object equality to find a member in a
181
+ collection. To check for an object equal to an item the collection, use
182
+ <b>Has.Some.EqualTo(...)</b>.
183
+ </ol>
184
+
185
+ <h3>CollectionEquivalentConstraint</h3>
186
+
187
+ <h4>Action</h4>
188
+ <p>Tests that two collections are equivalent - that they contain
189
+ the same items, in any order.
190
+
191
+ <h4>Constructor</h4>
192
+ <div class="code"><pre>
193
+ CollectionEquivalentConstraint( IEnumerable other )
194
+ </pre></div>
195
+
196
+ <h4>Syntax</h4>
197
+ <div class="code"><pre>
198
+ Is.EquivalentTo( IEnumerable other )
199
+ </pre></div>
200
+
201
+ <h4>Examples of Use</h4>
202
+ <div class="code"><pre>
203
+ int[] iarray = new int[] { 1, 2, 3 };
204
+ string[] sarray = new string[] { "a", "b", "c" };
72
205
 
73
206
  Assert.That( new string[] { "c", "a", "b" }, Is.EquivalentTo( sarray ) );
74
207
  Assert.That( new int[] { 1, 2, 2 }, Is.Not.EquivalentTo( iarray ) );
208
+ </pre></div>
209
+
210
+ <h4>Notes</h4>
211
+ <ol>
212
+ <li>To compare collections for equality, use Is.EqualTo().
213
+ </ol>
214
+
215
+ <h3>CollectionSubsetConstraint</h3>
216
+
217
+ <h4>Action</h4>
218
+ <p>Tests that one collection is a subset of another.
219
+
220
+ <h4>Constructor</h4>
221
+ <div class="code"><pre>
222
+ CollectionSubsetConstraint( ICollection )
223
+ </pre></div>
224
+
225
+ <h4>Syntax</h4>
226
+ <div class="code"><pre>
227
+ Is.SubsetOf( IEnumerable )
228
+ </pre></div>
229
+
230
+ <h4>Example of Use</h4>
231
+ <div class="code"><pre>
232
+ int[] iarray = new int[] { 1, 2, 3 };
233
+
75
234
  Assert.That( new int[] { 1, 3 }, Is.SubsetOf( iarray ) );
235
+ </pre></div>
76
236
 
77
- // Using inheritance
78
- Expect( iarray, All.GreaterThan( 0 ) );
79
- Expect( sarray, Contains("b") );
80
- Expect( new int[] { 1, 3 }, SubsetOf( iarray ) );
237
+ <h3>CollectionOrderedConstraint (NUnit 2.5)</h3>
238
+
239
+ <h4>Action</h4>
240
+ <p>Tests that a collection is ordered.
241
+
242
+ <h4>Constructor</h4>
243
+ <div class="code"><pre>
244
+ CollectionOrderedConstraint()
81
245
  </pre></div>
82
246
 
247
+ <h4>Syntax</h4>
248
+ <div class="code"><pre>
249
+ Is.Ordered
250
+ </pre></div>
251
+
252
+ <h4>Modifiers</h4>
253
+ <div class="code"><pre>
254
+ ...Descending
255
+ ...By(string propertyName)
256
+ ...Using(IComparer comparer)
257
+ ...Using<T>(IComparer&lt;T&gt; comparer)
258
+ ...Using<T>(Comparison&lt;T&gt; comparer)
259
+ </pre></div>
260
+
261
+ <h4>Examples of Use</h4>
262
+ <div class="code"><pre>
263
+ int[] iarray = new int[] { 1, 2, 3 };
264
+ string[] sarray = new string[] { "c", "b", "a" };
265
+ string[] sarray2 = new string[] ( "a", "aa", "aaa" );
266
+
267
+ Assert.That( iarray, Is.Ordered );
268
+ Assert.That( sarray, Is.Ordered.Descending );
269
+ Assert.That( sarray2, Is.Ordered.By("Length");
270
+ </pre></div>
271
+
272
+ <h4>Notes</h4>
273
+ <ol>
274
+ <li>Modifiers may be combined and may appear in any order. If the
275
+ same modifier is used more than once, the result is undefined.
276
+ <li>The syntax of Is.Ordered has changed from earlier betas.
277
+ </ol>
83
278
 
84
279
  </div>
85
280
 
86
281
  <!-- Submenu -->
87
282
  <div id="subnav">
88
283
  <ul>
89
- <li><a href="index.html">NUnit 2.4.8</a></li>
284
+ <li><a href="index.html">NUnit 2.5</a></li>
90
285
  <ul>
91
286
  <li><a href="getStarted.html">Getting&nbsp;Started</a></li>
92
287
  <li><a href="assertions.html">Assertions</a></li>
93
- <ul>
94
- <li><a href="classicModel.html">Classic&nbsp;Model</a></li>
95
- <li><a href="constraintModel.html">Constraint&nbsp;Model</a></li>
288
+ <li><a href="constraintModel.html">Constraints</a></li>
96
289
  <ul>
97
290
  <li><a href="equalConstraint.html">Equal&nbsp;Constraint</a></li>
98
291
  <li><a href="sameasConstraint.html">SameAs&nbsp;Constraint</a></li>
99
292
  <li><a href="conditionConstraints.html">Condition&nbsp;Constraints</a></li>
100
293
  <li><a href="comparisonConstraints.html">Comparison&nbsp;Constrants</a></li>
294
+ <li><a href="pathConstraints.html">Path&nbsp;Constraints</a></li>
101
295
  <li><a href="typeConstraints.html">Type&nbsp;Constraints</a></li>
102
296
  <li><a href="stringConstraints.html">String&nbsp;Constraints</a></li>
103
297
  <li id="current"><a href="collectionConstraints.html">Collection&nbsp;Constraints</a></li>
104
298
  <li><a href="propertyConstraint.html">Property&nbsp;Constraint</a></li>
299
+ <li><a href="throwsConstraint.html">Throws&nbsp;Constraint</a></li>
105
300
  <li><a href="compoundConstraints.html">Compound&nbsp;Constraints</a></li>
106
- <li><a href="customConstraints.html">Custom&nbsp;Constraints</a></li>
301
+ <li><a href="delayedConstraint.html">Delayed&nbsp;Constraint</a></li>
107
302
  <li><a href="listMapper.html">List&nbsp;Mapper</a></li>
108
303
  </ul>
109
- </ul>
110
304
  <li><a href="attributes.html">Attributes</a></li>
111
305
  <li><a href="nunit-console.html">Console&nbsp;Runner</a></li>
112
306
  <li><a href="nunit-gui.html">Gui&nbsp;Runner</a></li>
113
- <li><a href="features.html">Other&nbsp;Features</a></li>
307
+ <li><a href="configFiles.html">Configuration&nbsp;Files</a></li>
308
+ <li><a href="pnunit.html">PNUnit</a></li>
309
+ <li><a href="multiAssembly.html">Multiple&nbsp;Assemblies</a></li>
310
+ <li><a href="vsSupport.html">Visual&nbsp;Studio&nbsp;Support</a></li>
311
+ <li><a href="extensibility.html">Extensibility</a></li>
114
312
  <li><a href="releaseNotes.html">Release&nbsp;Notes</a></li>
115
313
  <li><a href="samples.html">Samples</a></li>
116
314
  <li><a href="license.html">License</a></li>
@@ -122,7 +320,7 @@ Expect( new int[] { 1, 3 }, SubsetOf( iarray ) );
122
320
 
123
321
  <!-- Standard Footer for NUnit.org -->
124
322
  <div id="footer">
125
- Copyright &copy; 2008 Charlie Poole. All Rights Reserved.
323
+ Copyright &copy; 2009 Charlie Poole. All Rights Reserved.
126
324
  </div>
127
325
  <!-- End of Footer -->
128
326