Skip to content
Snippets Groups Projects
Commit 880397ab authored by Olav Morken's avatar Olav Morken
Browse files

Test: Made test.php work if it was in a different directory than the current directory.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@305 44740490-163a-0410-bde0-09ae8108e29a
parent 1dce3f1a
No related branches found
No related tags found
No related merge requests found
......@@ -9,7 +9,18 @@
$tests = array();
require_once('../config/test.php');
/* The configuration file is relative to this script. */
$configFile = dirname(dirname(__FILE__)) . '/config/test.php';
/* Check if the configuration file exists. */
if(!file_exists($configFile)) {
echo('Missing configuration file: ' . $configFile . "\n");
echo('Maybe you need to copy config/test-template.php to config/test.php and update it?.' . "\n");
exit(1);
}
/* Load the configuration file. */
require_once($configFile);
/**
* This function creates a curl handle and initializes it.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment