Top 10 PHP automated testing frameworks

Source: Internet
Author: User
PHP automated testing framework top 10 from: http://my.oschina.net/u/2317468/blog/607775


For many new PHP developers, testing their own code is a very tricky issue. If something goes wrong, they will not know what to do next. It is unwise to spend a long time debugging PHP code. The best way is to write the test code before writing the application code. Automated testing can greatly ease and improve the workflow of PHP Development. it can help developers manage most tasks and focus more on testing code of development logic. This article will introduce you to the Top 10 PHP automated testing frameworks!

PHPUnit

PHP Unit is a lightweight PHP testing framework. It is a full migration of the JUnit 3 series in PHP 5 and a member of the xUnit Testing framework family (both based on the pattern pioneer Kent Beck's design ).

Unit testing is the basis of several modern Agile development methods, making PHPUnit a key tool for many large PHP projects. This tool can also be used by the Xdebug extension to generate code coverage reports, and can be integrated with phing for automatic testing. Finally, it can be integrated with Selenium to complete large-scale automated integration testing.

Selenium

Selenium is a tool used for Web application testing. Selenium test cases run directly in the browser, just as real users are operating. Compared with mainstream web automated testing frameworks such as QTP and Ruby-based WATIR, Selenium supports multiple browsers such as IE and Mozilla Firefox, supports automatic recording scripts, automatic generation of Java, c #, ruby, and other running languages, and quick and fast use case creation. Compared with Selenium, Selenium is more flexible and practical.

Codeception

Codeception is an excellent PHP testing framework with a full stack. it helps simplify the process of creating unit tests and functional acceptance tests. The Codeception extension simplifies application configuration during testing.

Behat

Behat is a behavior-driven development (BDD) framework that can test business expectations, allow users to write story-driven code that is easy to read, and describe how the application should work. Anyone can quickly and easily master how to use it.

Kahlan

Kahlan is a fully functional BDD testing framework that allows you to write unit tests using the syntax that describes it. It has a code base 10 times smaller than PHPUnit, providing developers with a scalable and customizable test process.

Atoum

Atoum is a modern, simple, and intuitive PHP 5.3 + unit testing framework, similar to SimpleTest and PHPUnit. It can quickly implement, simplify test development, and allow the compilation of reliable, readable, and concise unit tests.

Peridot

Peridot is a highly scalable and convenient PHP testing framework that supports PHP 5.4 +. Peridot makes the test more interesting! Developers can create plug-ins and customize test reports.

Storyplayer

Storyplayer is a full-stack testing framework that can write end-to-end tests for the entire platform. It follows the TDD test method and allows developers to write functional tests that can check applications.

PHPSpec

PHPSpec is the SpecBDD framework of PHP and is a PHP testing framework driven by standardized exceptions.

Mockery

Mockery is a simple and flexible PHP mock object framework, which is often used in unit tests of PHPUnit, PHPSpec, or other testing frameworks. Its core goal is to provide a two-way testing framework and a succint API that can clearly define all possible object operations and interactions.

PS: For PHP development, follow these products> This article is translated from codecondo.com. Please note that this article is reproduced from huidu control network!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.