When using the mock JDBC classes, if the method executeQuery is run using an SQL statement for which there is no resultset defined, null is returned. This is contrary to the API for jdbc. For the preparedstatement class, the executequery method cannot return null. An exception should be thrown instead.
According to the API:
a ResultSet object that contains the data produced by the query; never null"