开发者

PHPUnit and stored procedure

开发者 https://www.devze.com 2023-01-29 09:15 出处:网络
I am implementing PHPUnitin my system. But most of 开发者_JAVA技巧the logic part is handled in stored proecdure/

I am implementing PHPUnit in my system. But most of 开发者_JAVA技巧the logic part is handled in stored proecdure/ How do i write stored procedure for them?


PHPUnit has it's focus on PHP-testing. Calling a stored procedure in a database doesn't change that, you can still test your PHP-code. You PHPUnit-test can't test all the logic inside the stored procedure, but it can test the black box.

If you use PostgreSQL as your database, you could take a look at pgTAP for unit testing inside your database.

0

精彩评论

暂无评论...
验证码 换一张
取 消