Esempio n. 1
0
 /**
  * Tests Exists
  *
  * @author Nikos Dimopoulos <*****@*****.**>
  * @since  2012-10-30
  */
 public function testExists()
 {
     $language = $this->config['tr']['en'];
     $params = array('content' => $language);
     $translator = new PhTranslateAdapterNativeArray($params);
     $found = $translator->exists('hi');
     $this->assertTrue($found, 'Translator key does not exist');
 }
 /**
  * Tests whether a key exists in the array
  *
  * @author Nikolaos Dimopoulos <*****@*****.**>
  * @since  2014-09-12
  */
 public function testExists()
 {
     $this->specify("The key does not exist with exists", function () {
         $language = $this->config['en'];
         $params = ['content' => $language];
         $translator = new PhTTranslateAdapterNativeArray($params);
         $found = $translator->exists('hi');
         expect($found)->true();
     });
 }
Esempio n. 3
0
 public function exists($index)
 {
     return parent::exists($index);
 }