CodeIgniter Forums
Problem with Project-tests - Printable Version

+- CodeIgniter Forums (
+-- Forum: CodeIgniter 4 (
+--- Forum: CodeIgniter 4 Support (
+--- Thread: Problem with Project-tests (/thread-74791.html)

Pages: 1 2

RE: Problem with Project-tests - Poetawd - 11-09-2019

(11-09-2019, 05:45 PM)MGatner Wrote: Okay, I think I see what is happening. I believe you have the CodeIgniter "tests" folder in your root (this one: but you are forcing it to the ProjectTests namespace via composer.json ("ProjectTests\\Support\\": "tests/_support"). Make sure you have removed the CodeIgniter tests folder and all subfolders, then copy in the version from CodeIgniter4Projects/ProjectTests.

If I'm wrong about that let me know and we'll try something else.

Now I am a bit confused... I have to remove Codeigniter tests in order to ProjectTests to work ?  Huh

Guess not... Because it requires some files from Codeigniter test folder...

The tests folder I have in my root is the one that came with CI4 installation...

RE: Problem with Project-tests - MGatner - 11-10-2019

The tests folder that comes in the *root* of the CodeIgniter AppStarter and DevStarter (and manual installations from repo clone) is designed to test the framework itself. If you are planning on working on the framework, submitting PRs, bug reports, etc, then you should use that. If you are writing an app that uses the framework you can assume that the framework is passing its own tests and you do not need the tests folder (a copy is always available in vendor for Composer installs) - instead you want tests specific to your project, hence "ProjectTests". You will definitely have problems if you try to keep the framework tests in your root and add or merge ProjectTests - the two are set up very differently.

RE: Problem with Project-tests - Poetawd - 11-10-2019

I am using the tests folder that comes with the CI4 normal installation... The one available on the DOWNLOADS page... ... It comes with just tests/support_ ... That is what I am using...

RE: Problem with Project-tests - MGatner - 11-11-2019

Yes, still applicable. That is the latest release which is equivalent to the master branch of the repo. If you want to use ProjectTests you should remove that whole folder and replace it with the version from ProjectTests/src