Unit Testing With SimpleTest in PHP keeping getting file directory errors from relative paths?
-
13-09-2019 - |
Question
I am using Zend Framework MVC and unit-testing with SimpleTest library. I have a specific model that keeps failing because it uses Zend Cache and the cache directory is a relative path I was wondering if anyone has seen a problem like this b4. Thanks.
Solution
I had to make an absolute path using $_SERVER['DOCUMENT_ROOT'] that way no matter what file structure I am on it works. a Truly relative path. lol.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow