简体   繁体   中英

Testlink Installation problem with $tlCfg->results['status_code'] = array (

I am installing Testlink on a fairly vanilla laptop using XAMPP v3.3.0 and using testlink 1.8.5b and/or 1.9.0.

I am unable to find support online and the below is my error message that I get on both versions of Testlink that I have tried:

Fatal error: Uncaught Error: Attempt to modify property "results" on null in C:\Program Files\XAMPP\htdocs\testlink\cfg\const.inc.php:360 Stack trace: #0 C:\Program Files\XAMPP\htdocs\testlink\install\index.php(11): require_once() #1 {main} thrown in C:\Program Files\XAMPP\htdocs\testlink\cfg\const.inc.php on line 360

I receive this error once I start Xampp and going to http://localhost/testlink/install/index.php this is before I even get the Testlink installation window.

I have not yet made the changes to the directories in config.inc.php. At this point I have created the MySql user as advised via documentation but this occurs even before the creation of the user.

My config files everywhere is untouched across xampp and Testlink, and on Xampp Apache and MySQL (Tomcat) starts just fine.

Any advise that I might be missing?

Thank you in advance

I am also see this error message, however I couldnt find any resolution online either. My inline of error is on line 409 though not

//Fatal error: Uncaught Error: Attempt to modify property "results" on null in C:\xampp\htdocs\Testlink\cfg\const.inc.php:409 Stack trace: #0 C:\xampp\htdocs\Testlink\install\index.php(20): require_once() #1 {main} thrown in C:\xampp\htdocs\Testlink\cfg\const.inc.php on line 409 not 360//

    $tlCfg->results['status_code'] = array (
     'failed'        => 'f',
     'blocked'       => 'b',
     'passed'        => 'p',
     'not_run'       => 'n',
     'in_progress'   => 'i', 
     'not_available' => 'x',
     'unknown'       => 'u',
      'all'           => 'a'
      ); //

there is some issue that I also cannot indicate, but i try to download a different version or fix the version at https://github.com/TestLinkOpenSourceTRMS/testlink-code/tree/testlink_1_9_20_fixed

seems this code is successful in setup testlink. I try some workaround in your issue because it's similar to the issue that I had but no luck to make it.

I speak Spanish, sorry for the English.

Solution: Enter the file "..\testlink\cfg\const.inc.php" and locate line 360, it should look something like this:

$tlCfg->results['status_code'] = array (
'failed' => 'f',
'blocked' => 'b',
'passed' => 'p',

The problem is that the object was not previously initialized, for this we must place the following line of code to initialize the object and then be able to call it:

$tlCfg = new stdClass();

Now it should look something like this:

$tlCfg = new stdClass();
$tlCfg->results['status_code'] = array (
'failed' => 'f',
'blocked' => 'b',
'passed' => 'p',

You save and try, greetings and I hope I have helped.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM