Aleksander Machniak
2012-12-21 768e33a7955bd6f73c33363533843e41a720d29c
commit | author | age
e82492 1 <?php
AM 2
3 /*
4  +-----------------------------------------------------------------------+
5  | tests/bootstrap.php                                                   |
6  |                                                                       |
7  | This file is part of the Roundcube Webmail client                     |
8  | Copyright (C) 2009-2012, The Roundcube Dev Team                       |
9  |                                                                       |
10  | Licensed under the GNU General Public License version 3 or            |
11  | any later version with exceptions for skins & plugins.                |
12  | See the README file for a full license statement.                     |
13  |                                                                       |
14  | PURPOSE:                                                              |
15  |   Environment initialization script for unit tests                    |
16  +-----------------------------------------------------------------------+
17  | Author: Thomas Bruederli <roundcube@gmail.com>                        |
18  | Author: Aleksander Machniak <alec@alec.pl>                            |
19  +-----------------------------------------------------------------------+
20 */
21
22 if (php_sapi_name() != 'cli')
23   die("Not in shell mode (php-cli)");
24
25 if (!defined('INSTALL_PATH')) define('INSTALL_PATH', realpath(dirname(__FILE__) . '/..') . '/' );
26
27 define('TESTS_DIR', dirname(__FILE__) . '/');
28
29 if (@is_dir(TESTS_DIR . 'config')) {
30     define('RCMAIL_CONFIG_DIR', TESTS_DIR . 'config');
31 }
32
33 require_once(INSTALL_PATH . 'program/include/iniset.php');
9b05f1 34
AM 35 rcmail::get_instance()->config->set('devel_mode', false);