Forrest logo
tool overview
On this page you find all important commands for the CLI tool kahlan. If the command you are looking for is missing please ask our AI.

kahlan

Kahlan is a command line tool for PHP unit testing and mocking. It is named after the character in the book "Dune" by Frank Herbert.

  1. Kahlan is designed to make unit testing in PHP easier and more enjoyable.
  2. It has a simple, intuitive syntax that makes it easy to write tests.
  3. It provides a powerful mocking framework that allows you to easily create and configure mock objects.
  4. Kahlan supports various types of test doubles, including spies, stubs, and fakes.
  5. It uses descriptive syntax for expectations, making tests easy to read and understand.
  6. Kahlan allows you to group tests into "suites" for better organization and execution.
  7. It generates clear and informative error messages when tests fail, helping you quickly identify the issue.
  8. The tool provides coverage reports to show the percentage of code that was tested.
  9. Kahlan supports parallel execution of tests, improving performance when running a large test suite.
  10. It integrates well with popular PHP frameworks such as Laravel and Symfony, making it a versatile choice for testing PHP applications.

List of commands for kahlan:

  • kahlan:tldr:4711f kahlan: Run specifications with code coverage (detail can be between 0 and 4).
    $ kahlan --coverage=${detail_level}
    try on your machine
    explain this command
  • kahlan:tldr:4b9a4 kahlan: Run all specifications in the "spec" directory.
    $ kahlan
    try on your machine
    explain this command
  • kahlan:tldr:ae870 kahlan: Run specifications and output using a reporter.
    $ kahlan --reporter=${select}
    try on your machine
    explain this command
  • kahlan:tldr:c42e1 kahlan: Run specifications using a specific configuration file.
    $ kahlan --config=${path-to-configuration_file}
    try on your machine
    explain this command
tool overview