/** * Constructor. * * @access public * @return void */ public function setUp() { parent::setUp(); Mock::generate('Crumbly_model', get_class($this) . '_mock_model'); $this->_model = $this->_get_mock('model'); $this->_subject = new Crumbly_upd(); }
/** * Constructor. * * @access public * @return void */ public function setUp() { parent::setUp(); $this->_props = array('addon_name' => 'Example Add-on', 'admin_emails' => array('*****@*****.**', '*****@*****.**'), 'date' => time() - 1000, 'log_entry_id' => 100, 'message' => 'Example log entry.', 'extended_data' => 'Example extended data.', 'notify_admin' => TRUE, 'type' => Omnilog_entry::WARNING); $this->EE->email->setReturnValue('valid_email', TRUE); $this->_subject = new Omnilog_entry($this->_props); }
/** * Constructor. * * @access public * @return void */ public function setUp() { parent::setUp(); Mock::generate('Omnilog_model', get_class($this) . '_mock_model'); $this->EE->omnilog_model = $this->_get_mock('model'); $this->_model = $this->EE->omnilog_model; $this->_subject = new Omnilog_mcp(); }
/** * Constructor. * * @access public * @return void */ public function setUp() { parent::setUp(); Mock::generate('Omnilog_model', get_class($this) . '_mock_model'); $this->EE->omnilog_model = $this->_get_mock('model'); $this->_model = $this->EE->omnilog_model; $this->_log_entry_props = array('addon_name' => 'Example Add-on', 'date' => time() - 100, 'message' => 'Example log entry.', 'extended_data' => 'Example OmniLog extended data.', 'notify_admin' => FALSE, 'type' => Omnilog_entry::NOTICE); }
/** * Constructor. * * @access public * @return void */ public function setUp() { parent::setUp(); $this->_package_name = 'example_package'; $this->_package_version = '1.0.0'; $this->_site_id = 10; $this->EE->config->setReturnValue('item', $this->_site_id, array('site_id')); $this->_subject = new Omnilog_model($this->_package_name, $this->_package_version); }
/** * Constructor. * * @access public * @return void */ public function setUp() { parent::setUp(); // Generate the mock model. Mock::generate('Crumbly_model', get_class($this) . '_mock_model'); $this->_model = $this->_get_mock('model'); $this->EE->crumbly_model = $this->_model; $this->_site_id = 10; $this->EE->crumbly_model->setReturnValue('get_site_id', $this->_site_id); $this->_subject = new Crumbly(); }
/** * Constructor. * * @access public * @return void */ public function setUp() { parent::setUp(); // Dummy properties. $this->_namespace = 'example_namespace'; $this->_package_name = 'example_package'; $this->_package_version = '1.0.0'; // Dummy site ID value. $this->_site_id = 10; $this->EE->config->setReturnValue('item', $this->_site_id, array('site_id')); // Session cache. $this->EE->session->cache = array(); // The test subject. $this->_subject = new Crumbly_model($this->_package_name, $this->_package_version, $this->_namespace); }
/** * Constructor. * * @access public * @return void */ public function setUp() { parent::setUp(); $this->_props = array('addon_name' => 'Example Add-on', 'date' => time() - 1000, 'log_entry_id' => 100, 'message' => 'Example log entry.', 'notify_admin' => TRUE, 'type' => Omnilog_entry::WARNING); $this->_subject = new Omnilog_entry($this->_props); }