/**
  * Tests the detection of various Flash versions
  *
  * @access public
  * @return void
  */
 function testFlashDetection()
 {
     $_agent = env('HTTP_USER_AGENT');
     $_SERVER['HTTP_USER_AGENT'] = 'Shockwave Flash';
     $this->assertTrue($this->RequestHandler->isFlash());
     $_SERVER['HTTP_USER_AGENT'] = 'Adobe Flash';
     $this->assertTrue($this->RequestHandler->isFlash());
     $_SERVER['HTTP_USER_AGENT'] = 'Adobe Flash Player 9';
     $this->assertTrue($this->RequestHandler->isFlash());
     $_SERVER['HTTP_USER_AGENT'] = 'Adobe Flash Player 10';
     $this->assertTrue($this->RequestHandler->isFlash());
     $_SERVER['HTTP_USER_AGENT'] = 'Shock Flash';
     $this->assertFalse($this->RequestHandler->isFlash());
     $_SERVER['HTTP_USER_AGENT'] = $_agent;
 }
 /**
  * Tests the detection of various Flash versions
  *
  * @return void
  */
 public function testFlashDetection()
 {
     $request = $this->getMock('CakeRequest');
     $request->expects($this->once())->method('is')->with('flash')->will($this->returnValue(true));
     $this->RequestHandler->request = $request;
     $this->assertTrue($this->RequestHandler->isFlash());
 }