Can Yii1 legacy app be connected to Yii2, such that Yii2 takes care of unit/functional testing

Guys we built our product on Yii1 framework, and there is a lot of code, and lets just assume that currently for us to migrate to Yii2 is not an option.

Now Yii1 unit / functional / acceptance testing and PHPunit is broken, we are having a difficult time getting a solution. We are kind of trapped in Yii1.

One ray of hope comes from the fact that there are ways available through which Yii2 can be connected to Yii1 ( )

Is it possible / feasible to connect my current app to Yii2 and then manage all the unit / functional testing through Yii2. So that my app remains happy in Yii1 and Yii2 takes care of the testing part.

Experts suggest please

Added visualization of the above stuff, if it helps clarifying a bit more

Any response to this please …

This will not be exact answer you are looking for, but it can help maybe.

I think that your idea to keep Yii1 application is not good at all. Possible issues:

  • Yii1 doesn’t have support, except security

  • You are stuck with old versions of jquery and jquery ui, which are tested with you version of Yii. You can upgrade them but it can broke some functionality and you will need to fix it

  • You will miss lot of great improvements that comes with Yii2

I understand that re-writing existing application is lot of work, but you can do it in phases. For example, you can add totally separated Yii2 application and share session between two application (yii1 and yii2) and start rewriting existing functionality part by part. When you are ready with one functionality you can just change url to it, or make .htaccess rewrite that will handle that. That way you can still keep your Yii1 application working and all new features add to Yii2 and re-write one by one parts from Yii1 to Yii2. That way you will keep your clients happy and migrate to Yii2.

I hope that this help somehow :)