Jump to content
php.lv forumi
rpr

Yii2 codecept unit testi

Recommended Posts

Sveiki!

 

Gribēju patestēt untestus uz yii2 ar testiem jau integrēto codeception. Tomēr kaut kā nesanāk kā gribētos, funkcionālie testi smuki palaižas, bet uniti nē.

 

Šad tad bļauj ,ka konfig fails neeksistē @tests/codeception/config/unit.php, citreiz nevarielādēt modeļu klases, lai gan autoload ir ielādēts.

 

Izskatās, ka kaut ko fundamentāli daru nepareizi, bet gribējās ātro risinājumu. Varbūt kāds ir lietojis un zin kādu labu tutoriāli / dokumentāciju iemest ar to kā uzsetot to codeception?

Share this post


Link to post
Share on other sites

_bootrstra.php failā nācās pierakstīt divas rindas:

 

$config = require(__DIR__ . '/../config/console.php');
$application = new yii\console\Application( $config );

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...