{"title":"PyVideo.org - pyunit","link":[{"@attributes":{"href":"https:\/\/pyvideo.org\/","rel":"alternate"}},{"@attributes":{"href":"https:\/\/pyvideo.org\/feeds\/tag_pyunit.atom.xml","rel":"self"}}],"id":"https:\/\/pyvideo.org\/","updated":"2011-03-11T00:00:00+00:00","subtitle":{},"entry":[{"title":"Introduction to unittest (a.k.a. PyUnit) (#96)","link":{"@attributes":{"href":"https:\/\/pyvideo.org\/pycon-us-2010\/pycon-2010--introduction-to-unittest--a-k-a--pyun.html","rel":"alternate"}},"published":"2010-02-19T00:00:00+00:00","updated":"2010-02-19T00:00:00+00:00","author":{"name":"Chander Ganesan"},"id":"tag:pyvideo.org,2010-02-19:\/pycon-us-2010\/pycon-2010--introduction-to-unittest--a-k-a--pyun.html","summary":"<h3>Description<\/h3><p>Introduction to Unittest (a.k.a. PyUnit)<\/p>\n<p>Presented by Chander K Ganesan<\/p>\n<p>The PyUnit (unittest) unit testing framework provides an easy-to-use set\nof tools and techniques to add robust unit testing to your Python code.\nBy integrating unit testing in their code, developers allow for a robust\nset of \u2026<\/p>","content":"<h3>Description<\/h3><p>Introduction to Unittest (a.k.a. PyUnit)<\/p>\n<p>Presented by Chander K Ganesan<\/p>\n<p>The PyUnit (unittest) unit testing framework provides an easy-to-use set\nof tools and techniques to add robust unit testing to your Python code.\nBy integrating unit testing in their code, developers allow for a robust\nset of tools to quickly and easily identify &quot;broken&quot; code.<\/p>\n<p>In this session we'll explore the unittest module and demonstrate how to\nleverage PyUnit for unit testing.<\/p>\n","category":[{"@attributes":{"term":"PyCon US 2010"}},{"@attributes":{"term":"pycon"}},{"@attributes":{"term":"pycon2010"}},{"@attributes":{"term":"pyunit"}},{"@attributes":{"term":"testing"}},{"@attributes":{"term":"unittest"}}]},{"title":"Units Need Testing Too","link":{"@attributes":{"href":"https:\/\/pyvideo.org\/pycon-us-2011\/pycon-2011--units-need-testing-too.html","rel":"alternate"}},"published":"2011-03-11T00:00:00+00:00","updated":"2011-03-11T00:00:00+00:00","author":{"name":"Gary Bernhardt"},"id":"tag:pyvideo.org,2011-03-11:\/pycon-us-2011\/pycon-2011--units-need-testing-too.html","summary":"<h3>Description<\/h3><p>Units Need Testing Too<\/p>\n<p>Presented by Gary Bernhardt<\/p>\n<p>Python's long history of testing has focused primarily on integration-\nand system-level tests: slow-running tests executing lots of code. These\nare a great start, but many of them can be transformed into unit-level\ntests. True unit tests are orders of magnitude \u2026<\/p>","content":"<h3>Description<\/h3><p>Units Need Testing Too<\/p>\n<p>Presented by Gary Bernhardt<\/p>\n<p>Python's long history of testing has focused primarily on integration-\nand system-level tests: slow-running tests executing lots of code. These\nare a great start, but many of them can be transformed into unit-level\ntests. True unit tests are orders of magnitude faster (about 1ms each),\nproviding quicker feedback and better failure localization. We'll look\nat why and how to write them.<\/p>\n<p>Abstract<\/p>\n<p>Python has a wonderful legacy in testing: PyUnit has been in the\nstandard library since March, 2001, and it was already a year old by\nthen. We adopted browser driving quickly, and we do it at huge scale\nwith great test parallelization infrastructure.<\/p>\n<p>Big tests aren't everything, though. In the Python world, true unit\ntests are somewhat rare, and even most tests written with the unittest\nlibrary are integration tests. These tests are slow to execute and don't\nlocalize failure as well as smaller, focused tests. They leave us with\ntwo options: either run them rarely, sacrificing feedback, or run them\noften, sacrificing speed.<\/p>\n<p>Writing true unit tests removes that particular trade-off. When your\ntests execute in a millisecond each, you can afford to run a thousand of\nthem every time you save a source file. This talk will discuss what unit\ntests really are, why they matter, and how to write them in Python.<\/p>\n","category":[{"@attributes":{"term":"PyCon US 2011"}},{"@attributes":{"term":"pycon"}},{"@attributes":{"term":"pycon2011"}},{"@attributes":{"term":"pyunit"}},{"@attributes":{"term":"testing"}},{"@attributes":{"term":"unittests"}}]}]}