Example #1
0
 /**
  * Constructor
  * 
  * @param \Deal\Deal $app
  * @param \Deal\Model\BaseModel $model
  */
 public function __construct($app, $model = null)
 {
     $this->app = $app;
     $this->model = $model;
     // Convenience accessors
     $this->request = $app->request();
     $this->response = $app->response();
 }
Example #2
0
 public function testRespond()
 {
     Environment::mock(array('REQUEST_METHOD' => 'GET'));
     $deal = new Deal();
     $deal->respond('test');
     $this->assertEquals('test', unserialize($deal->response()->body()));
 }