Type json_array is not consistent with NULL values

Fields of type json_array are created as "TEXT NOT NULL".
If you then try to store a NULL value in that field, the database will convert it to an empty string.
The "convertToPHPValue" method for that type only checks for NULL when it converts NULL to array(), it does not check for an empty string.

Either the field creation in the database must be changed to allow nulls, or the test must be changed to also test for the empty string.