示例#1
0
 /**
  * Sets up before each test method runs.
  * This mainly sets the base URL for the test application.
  */
 protected function setUp()
 {
     $this->setBrowser('*googlechrome');
     $this->setBrowserUrl(TEST_BASE_URL);
     Yii::app()->request->setBaseUrl(TEST_BASE_URL);
     parent::setUp();
 }
示例#2
0
 /**
  * Sets up before each test method runs.
  * This mainly sets the base URL for the test application.
  */
 protected function setUp()
 {
     parent::setUp();
     $this->setBrowser('*firefox /usr/bin/firefox');
     //para linux
     //$this->setBrowser('*firefox'); //para windows
     $this->setBrowserUrl(TEST_BASE_URL);
 }
示例#3
0
 /**
  * Sets up before each test method runs.
  * This mainly sets the base URL for the test application.
  */
 protected function setUp()
 {
     parent::setUp();
     $this->setBrowser('*firefox');
     //$this->setTimeout(5);
     $this->setBrowserUrl(TEST_BASE_URL);
     $this->setSpeed(3000);
     //1000 is one second
 }
示例#4
0
 /**
  * Sets up before each test method runs.
  * This mainly sets the base URL for the test application.
  */
 protected function setUp()
 {
     parent::setUp();
     $tb_url = getenv('TEST_BASE_URL');
     if (!isset($tb_url)) {
         $tb_url = TEST_BASE_URL;
     }
     $this->setBrowserUrl($tb_url);
 }
示例#5
0
 /**
  * Sets up before each test method runs.
  * This mainly sets the base URL for the test application.
  */
 protected function setUp()
 {
     parent::setUp();
     $this->setBrowserUrl(TEST_BASE_URL);
 }
示例#6
0
 /**
  * Sets up before each test method runs.
  * This mainly sets the base URL for the test application.
  */
 protected function setUp()
 {
     parent::setUp();
     $this->setBrowserUrl(TEST_BASE_URL);
     $this->setTimeout(self::TIMEOUT);
 }
示例#7
0
 public function tearDown()
 {
     if (isset($this->_oldSession)) {
         $_SESSION = $this->_oldSession;
     }
     self::$skipAllTests = false;
     self::$loadFixtures = X2_LOAD_FIXTURES;
     self::$loadFixturesForClassOnly = X2_LOAD_FIXTURES_FOR_CLASS_ONLY;
     parent::tearDown();
 }
示例#8
0
 protected function setUp()
 {
     parent::setUp();
     $this->setBrowserUrl(TEST_BASE_URL);
     $this->db = Yii::app()->dbms;
 }
示例#9
0
 protected function setUp()
 {
     parent::setUp();
     $this->setBrowser("*firefox");
     $this->setBrowserUrl("http://localhost/demo-ebiobanques/index-test.php");
 }
示例#10
0
 /**
  * Sets up before each test method runs.
  * 
  * This mainly sets the base URL for the test application, and sets the 
  * Selenese path to make it easier to locate/use Selenese HTML scripts.
  */
 protected function setUp()
 {
     if (self::$skipAllTests) {
         $this->markTestSkipped();
     }
     if (self::$loadFixturesForClassOnly) {
         $this->getFixtureManager()->loadFixtures = true;
     }
     // print out test name
     VERBOSE_MODE && println("\n" . $this->getName());
     X2DbTestCase::setUpAppEnvironment(true);
     parent::setUp();
     $this->setSeleneseDir();
     // Set the screenshot path to one visible from the web.
     //$this->screenshotPath = Yii::app()->basePath . implode(DIRECTORY_SEPARATOR, array('', '..', 'uploads', 'testing'));
     //$this->screenshotUrl = rtrim(TEST_BASE_URL, 'index-test.php') . 'uploads/testing';
     $this->setBrowserUrl(TEST_BASE_URL);
     $this->prepareTestSession();
     if ($this->autoLogin) {
         $this->openX2('/site/login');
         $this->session();
     }
 }
示例#11
0
 /**
  * Sets up before each test method runs.
  * This mainly sets the base URL for the test application.
  */
 protected function setUp()
 {
     parent::setUp();
 }
示例#12
0
 public function tearDown()
 {
     if (isset($this->_oldSession)) {
         $_SESSION = $this->_oldSession;
     }
     parent::tearDown();
 }
示例#13
0
 protected function getAttribute($sel, $attr)
 {
     try {
         $attr = parent::getAttribute($sel . '@' . $attr);
     } catch (Exception $ex) {
         $attr = false;
     }
     return $attr;
 }
示例#14
0
 /**
  * Sets up before each test method runs.
  * This mainly sets the base URL for the test application.
  */
 protected function setUp()
 {
     parent::setUp();
     $this->setBrowser('*firefox');
     $this->setBrowserUrl('http://' . Yii::app()->params['hostname'] . '/');
 }