I am currently running PHP 7.1.2
Ci 3.06
PHPUnit 6.07
ci-phpuint-test 0.13.0
Database is : mysql Ver 15.1 Distrib 10.1.21-MariaDB, for osx10.12 (x86_64) using readline 5.1
It is my task to test an application.
None of the models do any input validation.
When I pass in a null instead of an array. I get an error :
Database error: A Database Error Occurred
Error Number: 1048
Column 'address_type_id' cannot be null
...
The functions was expecting an array but does not verify that the input is non-null.
I've tried this to catch this error and continue :
try {
some_function(null);
} catch(PHPUnit_Framework_ExpectationFailedException $e) {
echo $e->getMessage();
}
This does not catch the error.
The test dies.