Is there a way that a mock can just check for *some* of the parameters passed to a particular method, rather than all of them? I have mocked a database connection, and I'm using it in my language file. When I run:
Code: Select all
$lang->install();Code: Select all
$this->_db->insert('lang_strings', array(/*very large array of strings*/));Code: Select all
$mock_db->expect('insert', array('lang_strings'));All I want my mock to check for is that the database table name ('lang_strings') is correct - testing each element of the large array seems pointless and will create dependency in the test. If it's not possible for the Mock to only take notice of the first parameter, how do you suggest I test the lang class sufficiently?
Many thanks!