Changeset 104
- Timestamp:
- Thu Oct 12 12:05:52 2006
- Files:
-
- trunk/NEWS_0.9 (added)
- trunk/nose/__init__.py (modified) (diff)
- trunk/nose/selector.py (modified) (diff)
- trunk/index.html.tpl (modified) (diff)
- trunk/README.txt (modified) (diff)
- trunk/NEWS (modified) (diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
trunk/nose/__init__.py
r77 r104 104 104 ------------- 105 105 106 As with py.test and TestGears, nose tests need not be subclasses of 107 TestCase. Any function or class that matches the configured testMatch regular 108 expression ('(?:^|[\\b_\\.-])[Tt]est)'' by default) and lives in a module that 109 also matches that expression will be run as a test. For the sake of 110 compatibility with legacy unittest test cases, nose will also load tests from 111 unittest.TestCase subclasses just like unittest does. Like py.test and 112 TestGears, functional tests will be run in the order in which they appear in 113 the module file. TestCase derived tests and other test classes are run in 114 alphabetical order. 106 As with py.test, nose tests need not be subclasses of TestCase. Any function 107 or class that matches the configured testMatch regular expression 108 ('(?:^|[\\b_\\.-])[Tt]est)'' by default) and lives in a module that also 109 matches that expression will be run as a test. For the sake of compatibility 110 with legacy unittest test cases, nose will also load tests from 111 unittest.TestCase subclasses just like unittest does. Like py.test, functional 112 tests will be run in the order in which they appear in the module 113 file. TestCase derived tests and other test classes are run in alphabetical 114 order. 115 115 116 116 Fixtures … … 250 250 To report bugs, ask questions, or request features, please use the trac 251 251 instance provided by the great folks at python hosting, here: 252 http://nose.python-hosting. org. Or, email the author at252 http://nose.python-hosting.com. Or, email the author at 252 252 jpellerin+nose at gmail dot com. Patches are welcome! 253 253 … … 259 259 formerly was not all that easy to install, and is not based on unittest. 260 260 261 TestGears_ is a similar test runner (now part of TurboGears) that was 262 released during development of nose. TestGears is a little farther towards 263 the 'no magic' side of the testing axis, and integrates with setuptools 264 with a custom action. 265 266 Test suites written for use with nose should work equally well with either 267 py.test or TestGears, and vice versa, except for the differences in output 268 capture and command line arguments for the respective tools. 261 Test suites written for use with nose should work equally well with py.test, 262 and vice versa, except for the differences in output capture and command line 263 arguments for the respective tools. 269 264 270 265 .. _py.test: http://codespeak.net/py/current/doc/test.html 271 .. _TestGears: http://www.turbogears.com/testgears/272 266 273 267 License and copyright -
trunk/nose/selector.py
r95 r104 234 234 """Is the file a wanted test file? 235 235 236 If conf.file_only is defined, only that file matches. Otherwise, the237 root of the basename of the file must match test requirements.238 239 236 If self.tests is defined, the file must match the file part of a test 240 237 address in self.tests. … … 242 239 The default implementation ignores the package setting, but it is 243 240 passed in case plugins need to distinguish package from non-package 244 files. 241 files. 244 241 """ 245 242 -
trunk/index.html.tpl
r70 r104 23 23 } 24 24 25 #main {26 margin: 0px;27 padding: 0px;28 padding-right: 20px;29 width: 400px;30 float: left;31 }32 33 25 #menu { 34 26 padding-left 1em; 35 27 padding-right: 1em; 28 padding-bottom: 10px; 36 29 margin-left: 20px; 37 width: 200px; 30 min-width: 200px; 31 width: 20%%; 38 32 border-left: 1px solid #ddd; 39 float: left; 33 border-bottom: 1px solid #ddd; 34 background-color: #fff; 35 float: right; 40 36 } 37 38 #main { 39 margin: 0px; 40 padding: 0px; 41 padding-right: 20px; 42 width: 70%%; 43 float: left; 44 } 41 45 42 46 h1 { … … 124 128 </head> 125 129 <body> 130 131 132 <div id="menu"> 133 <h2><a href="nose-%(version)s.tar.gz">Download</a></h2> 134 <p>Current version: %(version)s <br />(%(date)s)</p> 135 136 <h2>Install</h2> 137 <p>Current version: <br /><tt>easy_install nose==%(version)s</tt></p> 138 <p>Unstable (trunk): <br /><tt>easy_install nose==dev</tt></p> 139 140 <h2>Read</h2> 141 <ul> 142 <li> 143 <a href="http://ivory.idyll.org/articles/nose-intro.html"> 144 An Extended Introduction to the nose Unit Testing Framework 145 </a> 146 <br />Titus Brown's excellent article provides a great overview of 147 nose and its uses. 148 </li> 149 <li><a href="#usage">nosetests usage</a> 150 <br />How to use the command-line test runner. 151 </li> 152 </ul> 153 154 <h2><a href="http://groups.google.com/group/nose-announce"> 155 Announcement list</a></h2> 156 <p>Sign up to receive email announcements 157 of new releases</p> 158 159 <h2><a href="http://nose.python-hosting.com/">Trac</a></h2> 160 <p>Report bugs, request features, wik the wiki, browse source.</p> 161 162 <h2>Get the code</h2> 163 <p><tt>svn co http://svn.nose.python-hosting.com/trunk</tt></p> 164 165 <h2>Other links</h2> 166 <ul> 167 <li><a href="/mrl/">My blog</a></li> 168 <li> 169 <a href="http://codespeak.net/py/current/doc/test.html">py.test</a> 170 </li> 171 <li><a href="http://www.turbogears.com/testgears/">testgears</a></li> 172 <li> 173 <a href="http://peak.telecommunity.com/DevCenter/setuptools">setuptools</a> 174 </li> 175 </ul> 176 </div> 126 177 <div id="main"> 127 178 <h1>nose: a discovery-based unittest extension.</h1> … … 185 236 186 237 </div> 187 <div id="menu">188 <h2><a href="nose-%(version)s.tar.gz">Download</a></h2>189 <p>Current version: %(version)s <br />(%(date)s)</p>190 191 <h2>Install</h2>192 <p>Current version: <br /><tt>easy_install nose==%(version)s</tt></p>193 <p>Unstable (trunk): <br /><tt>easy_install nose==dev</tt></p>194 195 <h2>Read</h2>196 <ul>197 <li>198 <a href="http://ivory.idyll.org/articles/nose-intro.html">199 An Extended Introduction to the nose Unit Testing Framework200 </a>201 <br />Titus Brown's excellent article provides a great overview of202 nose and its uses.203 </li>204 <li><a href="#usage">nosetests usage</a>205 <br />How to use the command-line test runner.206 </li>207 </ul>208 209 <h2><a href="http://groups.google.com/group/nose-announce">210 Announcement list</a></h2>211 <p>Sign up to receive email announcements212 of new releases</p>213 214 <h2><a href="http://nose.python-hosting.com/">Trac</a></h2>215 <p>Report bugs, request features, wik the wiki, browse source.</p>216 217 <h2>Get the code</h2>218 <p><tt>svn co http://svn.nose.python-hosting.com/trunk</tt></p>219 220 <h2>Other links</h2>221 <ul>222 <li><a href="/mrl/">My blog</a></li>223 <li>224 <a href="http://codespeak.net/py/current/doc/test.html">py.test</a>225 </li>226 <li><a href="http://www.turbogears.com/testgears/">testgears</a></li>227 <li>228 <a href="http://peak.telecommunity.com/DevCenter/setuptools">setuptools</a>229 </li>230 </ul>231 </div>232 238 233 239 </body> -
trunk/README.txt
r31 r104 104 104 ------------- 105 105 106 As with py.test and TestGears, nose tests need not be subclasses of 107 TestCase. Any function or class that matches the configured testMatch regular 108 expression ('(?:^|[\b_\.-])[Tt]est)'' by default) and lives in a module that 109 also matches that expression will be run as a test. For the sake of 110 compatibility with legacy unittest test cases, nose will also load tests from 111 unittest.TestCase subclasses just like unittest does. Like py.test and 112 TestGears, functional tests will be run in the order in which they appear in 113 the module file. TestCase derived tests and other test classes are run in 114 alphabetical order. 106 As with py.test, nose tests need not be subclasses of TestCase. Any function 107 or class that matches the configured testMatch regular expression 108 ('(?:^|[\b_\.-])[Tt]est)'' by default) and lives in a module that also 109 matches that expression will be run as a test. For the sake of compatibility 110 with legacy unittest test cases, nose will also load tests from 111 unittest.TestCase subclasses just like unittest does. Like py.test, functional 112 tests will be run in the order in which they appear in the module 113 file. TestCase derived tests and other test classes are run in alphabetical 114 order. 115 115 116 116 Fixtures … … 250 250 To report bugs, ask questions, or request features, please use the trac 251 251 instance provided by the great folks at python hosting, here: 252 http://nose.python-hosting. org. Or, email the author at252 http://nose.python-hosting.com. Or, email the author at 252 252 jpellerin+nose at gmail dot com. Patches are welcome! 253 253 … … 259 259 formerly was not all that easy to install, and is not based on unittest. 260 260 261 TestGears_ is a similar test runner (now part of TurboGears) that was 262 released during development of nose. TestGears is a little farther towards 263 the 'no magic' side of the testing axis, and integrates with setuptools 264 with a custom action. 265 266 Test suites written for use with nose should work equally well with either 267 py.test or TestGears, and vice versa, except for the differences in output 268 capture and command line arguments for the respective tools. 261 Test suites written for use with nose should work equally well with py.test, 262 and vice versa, except for the differences in output capture and command line 263 arguments for the respective tools. 269 264 270 265 .. _py.test: http://codespeak.net/py/current/doc/test.html 271 .. _TestGears: http://www.turbogears.com/testgears/272 266 273 267 License and copyright -
trunk/NEWS
r70 r104 1 New in version 0.9 1 New in version 0.9.1 2 -------------------- 2 3 3 0.9 Final is here! 4 ================== 4 Nose 0.9.1 is mainly a bug-fix release, but it does contain a few new 5 features: 5 6 6 nose 0.9 includes a host of new features, as well as numerous7 backwards-incompatible changes to interfaces and implementation.8 7 9 Thanks to the many folks who have contributed patches and ideas and made bug10 reports for the development version of 0.9, especially Mika Eloranta, Jay11 Parlar, Kevin Dangoor, Scot Doyle, Titus Brown and Philip J.Eby.12 13 Here's a quick rundown of what's new in 0.914 15 16 The most important new feature is support for plugins using setuptools17 entrypoints. nose plugins can select and load tests (like the builtin18 doctest plugin), reject tests (like the builtin attrib plugin, contributed19 by Mika Eloranta, that allows users to select tests by attribute),20 watch and report on tests (like the builtin coverage and profiler plugins),21 completely replace test result output (like the html result plugin in the22 examples directory) or any combination of the above. Writing plugins is23 simple: subclass nose.plugins.Plugin and implement any of the methods in24 nose.plugins.IPluginInterface.25 26 27 Test loading has been consolidated into a test loader class that is drop-in28 compatible with unittest.TestLoader. Likewise test result output, including29 output capture, assert introspection, and support for skipped and deprecated30 tests, in nose.result.TextTestResult. If you want those features and not the31 rest of nose, you can use just those classes. nose.main() has also been32 rewritten to have the same signature as unittest.main().33 34 35 Command line test selection is more intuitive and powerful, enabling easy36 and correct running of single tests while ensuring that fixtures (setup and37 teardown) are correctly executed at all levels. No more -f -m or -o options:38 now simply specify the tests to run::39 40 nosetests this/file.py that.module41 42 Tests may be specified down to the callable::43 44 nosetests this/file.py:TestClass that.module:this_test45 nosetests that.module:TestClass.test_method46 47 There are also new options for dropping into pdb on errors or failures, and48 stopping the test run on the first error or failure (thanks to Kevin Dangoor49 for the idea).50 51 52 Helpful test decorators and functions in nose.tools. Support for generators53 in test classes. Better import path handling -- that you can shut off!54 Detailed verbose logging using the logging package. And more...
