05580nam 2200721 450 991045832230332120200520144314.01-78328-344-0(CKB)2550000001307916(EBL)1674865(SSID)ssj0001295146(PQKBManifestationID)11731531(PQKBTitleCode)TC0001295146(PQKBWorkID)11337054(PQKB)10037981(MiAaPQ)EBC1674865(CaSebORM)9781783283439(PPN)228008581(Au-PeEL)EBL1674865(CaPaEBR)ebr10879007(CaONFJC)MIL613602(OCoLC)880826827(EXLCZ)99255000000130791620140615h20142014 uy 0engur|n|---|||||txtccrPHPUnit essentials get started with PHPUnit and learn how to write and test code using advanced technologies /Zdenek Machek ; cover image by Asher Wishkerman1st editionBirmingham, England :Packt Publishing,2014.©20141 online resource (314 p.)Community Experience DistilledIncludes index.1-78328-343-2 1-306-82351-X Cover; Copyright; Credits; About the Author; About the Reviewers; www.PacktPub.com; Table of Contents; Preface; Chapter 1: Installing PHPUnit; Requirements; Running PHP from the command line; Composer - the dependency manager for PHP; Installing Composer; Installation; Local installation; System-wide installation; Installing PEAR; Installing PHPUnit; Other installation methods; Installing the Linux package; Manual installation; Testing the installation; Xdebug; Installing Xdebug; Summary; Chapter 2: PHPUnit Support in IDEs; IDEs and PHPUnit; NetBeans; Zend Studio; Eclipse PDTInstalling MakeGoodCreating your FirstTest; PhpStorm; Summary; Chapter 3: Tests and What They're All About; Understanding unit testing; What is a unit test?; Assertions; The importance of unit testing; Testing all possible scenarios; What makes a good test?; When to write tests; Anatomy of a PHPUnit test; Defining test methods; Testing functions; Testing methods; The MVC application architecture and tests; Testing controllers; Summary; Chapter 4: Testing Dependencies and Exceptions; Detecting dependencies; Handling dependencies; Exceptions are expected; Testing errors and exceptions; SummaryChapter 5: Running Tests from the Command LineRunning tests; Processing test results; Test statuses; Command-line switches; Logging results; Code coverage; Including and excluding tests from the execution; When to stop the test execution; Configuration options; Code coverage analysis; Summary; Chapter 6: Test Isolation and Interaction; Test fixtures; Before and after each test method; Before and after each test suite class; Global state; Test dependencies; Data providers; Summary; Chapter 7: Organizing Tests; The PHPUnit XML configuration file; Test listeners; Configuring the code coverageWhere to store testsTest suites; Groups; Using the bootstrap file; Summary; Chapter 8: Using Test Doubles; Creating test doubles; Test doubles in action; Using fake; Using stubs; Using mocks and expectations; Test proxies; Understanding Mockery; Installation methods; Comparing Mockery to PHPUnit; How to use Mockery; Summary; Chapter 9: Database Testing; Which database to use; Tests for a database; DBUnit; Installing DBUnit; Database test cases; Datasets; Using DBUnit; Doctrine 2 ORM and database testing; Summary; Chapter 10: Testing APIs; An example of integration testingTesting the PayPal APITesting the Facebook API; Testing the Twitter API; Testing the service-oriented architecture; Summary; Chapter 11: Testing Legacy Code; Testing spaghetti code; Black box testing; Using Reflection; Handling dependencies; The Patchwork library; The vfsStream library; The runkit PHP extension; Summary; Chapter 12: Functional Tests in the Web Browser Using Selenium; Installing Selenium; The Selenium IDE; The Selenium Server; Installing drivers; The PHPUnit Selenium extension; Testing in the browser; Recording Selenium tests; PHPUnit Selenium2TestCase; Writing Selenium testsPHP-SeleniumClientThis book is a practical guide featuring a step-by-step approach that aims to help PHP developers who want to learn or improve their software testing skills. It also takes you through many real-life examples encountered by PHP developers to help you avoid common pitfalls.This book is for developers who have experience with PHP and who want to take their coding skills to another level. Developers who have previous experience with PHPUnit will find interesting chapters concerning PHPUnit in the context of web application development.Community experience distilled.Application softwareDevelopmentComputer programmingJavaScript (Computer program language)Electronic books.Application softwareDevelopment.Computer programming.JavaScript (Computer program language)005.1Machek Zdenek982331Wishkerman AsherMiAaPQMiAaPQMiAaPQBOOK9910458322303321PHPUnit essentials2242111UNINA