You searched for phpunit

  1. Thoughts of a Pragmatic Tester

    thinks, "I need to do unit tests, and I should use PHPUnit because it's a standard. I don't know much about it, though." Then he visits the PHPUnit site and reads the first chapter of the documentation, then the second, then the third... and is left scratching his head. "Does everyone write
  2. More Debate on PEAR

    , how successful communities are built. - Accept Simple Test as an alternative PHPUnit. Sorry but (someone needs to stick their neck out) PHPUnit just doesn't cut the grade. Missing features like Mock Objects are essential. Right now I guess only about 20% (if that) of PEAR packages come with unit
  3. More Bulletproofing with PHPUnit’s Database Extension

    the operation I've written this article to be self-contained so that you won't have to read my first tutorial beforehand, but if you are new to Test Driven Development, I highly recommend you read it as well as the introduction to PHPUnit by Michelle Saver. To follow along with this article
  4. Maven and PHP

    the PHP-Maven plugin from the command line and in Eclipse. Install Maven PHP-Maven uses the power of Maven for building, reporting, and creating documentation of your PHP projects. It adapts the Maven build life cycle to the PHP world while fully supporting PHP 5. PHP-Maven uses PHPUnit for unit
  5. Be More Asssertive: Getting to Know PHPUnit's Assertions+

    In my previous article, I took you through some of the basics of unit testing with PHPUnit. I introduced you to what it means to test your code and the real benefits it can for you and your code. This time I want to dive in a little deeper and get to know PHPUnit in a bit more detail. Marking Tests
  6. Preventing Code Rot 101: Unit Testing

    ("John", "tim", "bob", "Martin"); } } <?php ... //**PHPUnit testcase **/ public function setUp() { //mock file included instead of real file $this->db = new DBLayer(); } public function
  7. Continuous Integration with Jenkins, Part 1

    is continuously checking whether new code works as it is supposed to before committing it to the Git repository. This is called unit testing, and it can be carried out in PHP with the help of Sebastian Bergmann’s PHPUnit framework. Apparently it was Miwa who read my colleague Michelle Sanver’s Getting
  8. Using Phing, the PHP Build Tool

    can install Phing using PEAR: shameer@yukon:~$ sudo pear channel-discover shameer@yukon:~$ sudo pear install phing/phing If you wish to use tasks like PHPUnit or PhpDocumentor then you'll also need to install the dependent packages. Phing Hello World To show you how easy
  9. Continuous Integration with Jenkins, Part 2

    it running. Demonstration Project The demo project is based on the User class and its test script used by Michelle Sanver in her article Getting Started with PHPUnit. To keep things organized, I created a directory called workspace in my home directory and set it up like this: workspace has
  10. Goodbye CodeIgniter, Hello Laravel

    . In Laravel it’s easier. You have Tasks using the command line tool that Laravel comes with called Artisan. Miscellaneous Unit Testing – Codeigniter uses a very rudimentary testing class for writing unit tests. It is limited, but you can integrate PHPUnit. Laravel comes with PHPUnit out
  11. phpDay 2013: News and Highlights

    and showed some examples of how it can simplify the creation of mocks compared other frameworks like PHPUnit. It seems a very promising project, but I can't give an honest assessment of it since I haven't tried it and don't have much experience with mocking. There's not enough space to write about
  12. Ruling the Swarm (of Tests) with Codeception

    PHP testing framework built on top of Symfony2 components, Mink, and PHPUnit. Codeception includes more than 20 modules to test over popular PHP frameworks, APIs (REST, SOAP), data stores (MySQL, PostgreSQL, MongoDB, etc) and web with Selenium WebDriver. Check it out on the official web site
  13. pTest: PHP Unit Tester in 9 Lines Of Code

    for such a simple testing function is introducing the uninitiated into the world of unit testing. I know that before I got into it, the biggest barrier was the complexity of the frameworks. Perhaps pTest will give beginners a starting point, from which they can move onto more feature-rich frameworks like PHPUnit or SimpleTest once they outgrow the humble assertTrue().
  14. Advanced PHP Programming: George Schlossnagle

    practices" and where most talk of PHP itself happens - subjects like coding standard, OOP, CVS, unit testing and so on. George "dares" to use Smarty and PHPUnit, which probably won't please everyone but the concepts are transferable. The style of the book is discussion and "enablement" rather than
  15. An Introduction to Mock Object Testing

    this dependency. You can now start programming the business logic you are tasked to do and pass the test. PHPUnit 3.6.7 by Sebastian Bergmann. F Time: 0 seconds, Memory: 3.00Mb There was 1 failure: 1) StatusServiceTest::testGetAnalytics null does not match expected type "array". /home/jeune/mock-object
  16. News Wire: PHP 4’s Days are Numbered

    speed the transition to PHP 5.2 This grassroots campaign calls for PHP developers to cease support for PHP 4 in new releases of their projects from Tuesday, February 5th, 2008. Significant projects include Swift Mailer, PHPUnit, Drupal, phpMyAdmin, Typo3 and Symfony. (tags: php hosting opensource
  17. Using YAML in Your PHP Projects

    () are available with the sfYaml class. Editor Note Oct 28 2012: The accompanying code on GitHub has been updated to use Composer for obtaining the PHPUnit and Symfony 1.4 YAML Component dependencies. Integrating a PHP YAML Parser into Your Project Whenever you integrate a third-party class
  18. Web Routing in PHP with Aura.Router

    with the file structure below: All the source files lie in the src directory, and from there follows the PSR-0 Standard for autoloaders. All unit tests reside in the tests directory; you can run the tests by invoking phpunit inside the tests directory (just be sure you have PHPUnit installed
  19. 10 Tips for Better Coding

    the testing process. Testing (particularly systematic testing) is crucial to every piece of your million dollar application. Good testing tools are PHPUnit and SimpleTest for unit testing your PHP Classes. For GUI testing, I recommend SeleniumHQ tools. Summary In this article you saw an overview
  20. PHP's Quest for Performance: From C to hhvm

    Sebastian Bergmann, lead developer of PHPUnit; David Coallier, PEAR President and CTO of echolibre; and Brandon Savage, a developer at Mozilla. Overall, its reception was positive, and development on the project continued. Facebook worked with several popular projects in the PHP community, including