Overview

Packages

  • tipy

Classes

  • Tipy
  • TipyApp
  • TipyCli
  • TipyCliSession
  • TipyConfig
  • TipyController
  • TipyCookie
  • TipyDAO
  • TipyEnv
  • TipyFlash
  • TipyInflector
  • TipyInput
  • TipyIOWrapper
  • TipyLogger
  • TipyMailer
  • TipyModel
  • TipyOutput
  • TipyRequest
  • TipySession
  • TipyTestCase
  • TipyTestRunner
  • TipyView

Exceptions

  • AssertionFailedException
  • CompileErrorException
  • CompileWarningException
  • CoreErrorException
  • CoreWarningException
  • DeprecatedException
  • NoMethodException
  • NoticeException
  • ParseException
  • RecoverableErrorException
  • StrictException
  • TipyDaoException
  • TipyException
  • TipyModelException
  • TipyRollbackException
  • TipyValidationException
  • UserDeprecatedException
  • UserErrorException
  • UserNoticeException
  • UserWarningException
  • WarningException
  • Overview
  • Package
  • Class
  • Deprecated
  • Todo

Class TipyTestRunner

Run tests and print summary

$runner = new TipyTestRunner();
$exitCode = $runner->run();
exit($exitCode);

./bin/test

tipy comes with a script to execute tests in your application's tests directory

Let's say tipy is installed with Composer in vendor directory. Then you can run from your application root directory:

./vendor/tipy/tipy/bin/test tests/

TipyTestRunner will find all tests and fixtures in tests/ directory recursively and execute them.

If you want to run specific test case or use specific fixture file you can specify them as arguments. Tipy recognize test by filename ( *Test.php) and fixture by .sql extension. More than one tests and fixtures are allowed.

./vendor/tipy/tipy/bin/test tests/SpecificTest.php tests/fixtures/specific.sql

config.ini

You can specify different config files for production mode and for tests Tipy will look for config.ini

  • first in tests directory
  • then in application root directory

autoload.php

By default tipy uses your application's autoload.php located in app directory. But if you want to add some mocks for tests you can place one more autoload.php into tests directory and TipyTestRunner will use it also

Package: tipy
See: TipyTestCase
Located at src/TipyTestUnit.php
Methods summary
public integer
# run( )

Run tests

Run tests

Returns exit status:

  • 0 - all tests passed
  • 1 - there were errors or failures

Returns

integer
Properties summary
public array $fixtures

Paths to fixtures

Paths to fixtures

#
public array $skipDirs

Directory names to skip when looking for tests

Directory names to skip when looking for tests

# ['.git', '.svn', 'vendor']
tipy API documentation generated by ApiGen