
۴۴٬۰۰۰تومان
نوع فایل دانلود: EPUB
پس از خرید، یک فایل EPUB دریافت میکنید.
این فایل با Calibre، Apple Books و سایر کتابخوانهای دیجیتال مناسب است.
تولید گزارش ایجاد یک گزارش XML؛ ایجاد یک گزارش HTML؛ ایجاد خروجی رنگی در کنسول؛ اجرای تستهای unittest از طریق nose؛ مزایای nose نسبت به unittest؛ معایب nose؛ استفاده از Nose 2؛ جمعبندی؛ فصل ۵: pytest؛ مقدمهای بر pytest؛ تست ساده؛ اجرای تستها با دستور py.test؛ کلاس تست و پکیج تست در pytest؛ کشف تستها در pytest؛ فیکسچرهای سبک xUnit؛ پشتیبانی pytest برای unittest و nose؛ مقدمهای بر فیکسچرهای pytest؛ محدودهٔ فیکسچرهای pytest؛ pytest.raises()؛ گزینههای مهم خط فرمان pytest؛ راهنما؛ مقدمهای بر xUnit استفاده از Unittest؛ ترتیب اجرای متدهای تست؛ کنترل میزان توضیحات (Verbosity)؛ چند کلاس تست در یک فایل/ماژول تست؛ فیکسچرهای تست؛ اجرای بدون unittest.main()؛ کنترل میزاندانهای اجرای تست؛ فهرستکردن همهٔ گزینههای خط فرمان و راهنما؛ گزینههای مهم خط فرمان؛ ایجاد یک پکیج تست؛ سازماندهی کد؛ قرار دادن کد توسعه و تست در یک پوشهٔ واحد؛ قرار دادن کد توسعه و تست در پوشههای جداگانه؛ کشف تستها؛ قراردادهای کدنویسی برای unittest؛ Assertionها در unittest؛ سایر متدهای مفید؛ نصب در Fedora و CentOS؛ نصب در MacOS X؛ نصب در Windows؛ اجرای یک برنامهٔ پایتون و حالتهای مختلف پایتون؛ حالت تعاملی؛ حالت عادی؛ محیطهای توسعه (IDEs) برای پایتون؛ IDLE؛ پلاگین PyDev برای Eclipse؛ Geany؛ PyCharm؛ جمعبندی؛ فصل ۲: شروع کار؛ مقدمهای کوتاه بر مفاهیم آزمون نرمافزار؛ تست واحد (Unit Testing)؛ خودکارسازی تست؛ مزایای خودکارسازی تستهای واحد؛ استفاده از Docstringها؛ یک نمونه از Docstring در پایتون؛ مقدمهای کوتاه بر doctest؛ تستهای ناموفق؛ فایل تست جداگانه؛ مزایا و معایب doctest؛ جمعبندی؛ فصل ۳: Unittest؛ ناموفق شدن یک تست؛ استثناها در مورد تستکیس؛ assertRaises()؛ جمعبندی؛ فصل ۴: nose و nose2؛ مقدمهای بر nose؛ نصب nose روی سیستمعامل Linux؛ نصب nose روی MacOS و Windows؛ بررسی صحت نصب؛ شروع کار با nose؛ یک تستکیس سادهٔ nose؛ اجرای ماژول تست با nosetests؛ دریافت کمک؛ سازماندهی کد تست؛ کشف تستها؛ فیکسچرها برای کلاسها، ماژولها و متدها؛ فیکسچرها برای توابع؛ فیکسچرها برای پکیجها؛ نامهای جایگزین فیکسچرهای nose؛ assert_equals()؛ ابزارهای تست؛ ok_ و eq_؛ دکوریتور @raises()؛ دکوریتور @timed(). این کتاب به شما نشان میدهد چگونه تستهای واحد کد پایتون ۳ را خودکار کنید؛ با معرفی کتابخانههای مختلف خودکارسازی پایتون ۳ مانند doctest، unittest، nose، nose2 و pytest. همچنین مفاهیم مهم در آزمون نرمافزار و شیوهٔ پیادهسازی آنها در پایتون ۳ را بررسی میکند. آشنایی عملی با چارچوبها کمک میکند تا تستهای واحد خود را در پایتون ۳ خودکار، سازماندهی و اجرا کنید. دانشی که دربارهٔ چارچوبهای مطرحشده در این کتاب به دست میآید معمولاً از خواندن کد منبع، راهنماها و مطرحکردن سؤالها در انجمنهای کاربری حاصل میشود. این روند معمولاً کند و طاقتفرساست. Python Unit Test Automation به خوانندگان کمک میکند تا سریعتر درک خود را از کتابخانههای تست واحد پایتون ۳ با استفادهٔ عملی از مثالهای کدنویسی و تمرینها افزایش دهند. در نتیجه، این کتاب منبعی عالی برای توسعهدهندگان نرمافزار و تستکنندگان است که میخواهند با خودکارسازی تستهای واحد در پایتون ۳ شروع کنند؛ در یک نگاه؛ فهرست مطالب؛ دربارهٔ نویسنده؛ دربارهٔ داوران فنی؛ تقدیر و تشکرها؛ مقدمه؛ فصل ۱: آشنایی با پایتون؛ تاریخچهٔ پایتون؛ ویژگیهای پایتون؛ ساده؛ یادگیری آسان؛ خواندن آسان؛ نگهداری آسان؛ متنباز؛ زبان سطحبالا؛ قابلحمل؛ مفسری (interpreted)؛ شیءگرا (Object-Oriented)؛ گسترشپذیر (Extensible)؛ کتابخانههای گسترده؛ پایدار و مقاوم (Robust)؛ نمونهسازی سریع (Rapid Prototyping)؛ مدیریت حافظه؛ قدرتمند؛ پشتیبانی جامعهٔ کاربری؛ پایتون ۳؛ تفاوتهای پایتون ۲ و پایتون ۳؛ چرا از پایتون ۳ استفاده کنیم؛ نصب پایتون ۳؛ نصب روی Linux؛ نصب روی Debian، Ubuntu و توزیعهای مشتق.
Report GenerationCreating an XML Report; Creating an HTML Report; Creating Color Output in the Console; Running unittest Tests from nose; Advantages of nose over unittest; Disadvantages of nose; Using Nose 2; Conclusion; Chapter 5: pytest; Introduction to pytest; Simple Test; Running Tests with the py.test Command; Test Class and Test Package in pytest; Test Discovery in pytest; xUnit-Style Fixtures; pytest Support for unittest and nose; Introduction to pytest Fixtures; Scope of pytest Fixtures; pytest.raises(); Important pytest Command-Line Options; Help.;Introduction to xUnitUsing Unittest; Order of Execution of the Test Methods; Verbosity Control; Multiple Test Classes Within the Same Test File/Module; Test Fixtures; Running Without unittest.main(); Controlling the Granularity of Test Execution; Listing All the Command-Line Options and Help; Important Command-Line Options; Creating a Test Package; Organizing the Code; Placing the Development and Test Code in a Single Directory; Placing the Development and Test Code in Separate Directories; Test Discovery; Coding Conventions for unittest; Assertions in unittest; Other Useful Methods.;Installation on Fedora and CentOSInstallation on MacOS X; Installation on Windows; Running a Python Program and Python Modes; Interactive Mode; Normal Mode; IDEs for Python; IDLE; The PyDev Plugin for Eclipse; Geany; PyCharm; Conclusion; Chapter 2: Getting Started; A Brief Introduction to Software Testing Concepts; Unit Testing; Test Automation; The Benefits of Automated Unit Testing; Using Docstrings; Example of a Docstring in Python; A Brief Introduction to doctest; Failing Tests; Separate Test File; Advantages and Disadvantages of doctest; Conclusion; Chapter 3: Unittest.;Failing a TestExceptions in the Test Case; assertRaises(); Conclusion; Chapter 4: nose and nose2; Introduction to nose; Installing nose on Linux OS; Installing nose on MacOS and Windows; Verifying the Installation; Getting Started with nose; A Simple nose Test Case; Running the Test Module with nosetests; Getting Help; Organizing the test code; Test Discovery; Fixtures for Classes, Modules, and Methods; Fixtures for Functions; Fixtures for Packages; Alternate Names of the nose Fixtures; assert\_equals(); Testing Tools; ok\_ and eq\_; The @raises() Decorator; The @timed() decorator.;This book shows readers how to automate unit testing of Python 3 code by introducing various Python 3 automation libraries, such as doctest, unittest, nose, nose2, and pytest. It also explores the important concepts in software testing and their implementation in Python 3. Hands-on knowledge of the frameworks helps readers to automate, organize, and execute their unit tests for Python 3. Knowledge of the frameworks discussed in the book is often acquired by reading source code, manuals, and posting questions on community forums. This tends to be a slow and painful process. Python Unit Test Automation will allow readers to quickly ramp up their understanding of unit test libraries for Python 3 through the practical use of code examples and exercises. All of which makes this book a great resource for software developers and testers who want to get started with unit test automation in Python 3.;At a Glance; Contents; About the Author; About the Technical Reviewers; Acknowledgments; Introduction; Chapter 1: Introduction to Python; The History of Python; Features of Python; Simple; Easy to Learn; Easy to Read; Easy to Maintain; Open Source; High-Level Language; Portable; Interpreted; Object-Oriented; Extensible; Extensive Libraries; Robust; Rapid Prototyping; Memory Management; Powerful; Community Support; Python 3; The Differences Between Python 2 and Python 3; Why Use Python 3; Installation of Python 3; Installation on Linux; Installation on Debian, Ubuntu, and Derivatives.