fenom/tests/autoload.php

39 lines
914 B
PHP
Raw Normal View History

2013-01-25 18:36:16 +04:00
<?php
2013-09-05 03:35:02 +04:00
$loader = include(__DIR__ . "/../vendor/autoload.php");
/* @var Composer\Autoload\ClassLoader $loader */
2014-02-27 16:30:44 +04:00
$loader->add('Fenom', __DIR__ . '/cases');
2013-01-25 18:36:16 +04:00
2013-07-29 14:58:14 +04:00
define('FENOM_RESOURCES', __DIR__ . "/resources");
2013-01-25 18:36:16 +04:00
2013-07-29 14:58:14 +04:00
require_once FENOM_RESOURCES . "/actions.php";
require_once __DIR__ . "/TestCase.php";
2013-02-15 01:49:26 +04:00
2013-07-24 19:37:07 +04:00
ini_set('date.timezone', 'Europe/Moscow');
2013-07-29 14:58:14 +04:00
function drop()
{
2013-02-15 01:49:26 +04:00
call_user_func_array("var_dump", func_get_args());
$e = new Exception();
2013-07-29 14:58:14 +04:00
echo "-------\nDump trace: \n" . $e->getTraceAsString() . "\n";
2013-02-15 01:49:26 +04:00
exit();
2013-06-08 00:08:00 +04:00
}
2013-07-29 14:58:14 +04:00
function dump()
{
foreach (func_get_args() as $arg) {
fwrite(STDERR, "DUMP: " . call_user_func("print_r", $arg, true) . "\n");
2013-06-08 00:08:00 +04:00
2013-07-29 14:58:14 +04:00
}
2014-02-22 20:34:53 +04:00
}
function dumpt()
{
foreach (func_get_args() as $arg) {
fwrite(STDERR, "DUMP: " . call_user_func("print_r", $arg, true) . "\n");
}
$e = new Exception();
echo "-------\nDump trace: \n" . $e->getTraceAsString() . "\n";
2013-02-15 01:49:26 +04:00
}