/**
  * GeocoderBehaviorTest::testMinInc()
  *
  * @return void
  */
 public function testMinInc()
 {
     $this->Addresses->removeBehavior('Geocoder');
     $this->Addresses->addBehavior('Geo.Geocoder', ['real' => false, 'min_accuracy' => Geocode::ACC_SUBLOC]);
     $this->assertEquals(Geocode::ACC_SUBLOC, $this->Addresses->behaviors()->Geocoder->config('min_accuracy'));
     $data = ['city' => 'Neustadt'];
     $entity = $this->_getEntity($data);
     $res = $this->Addresses->save($entity);
     $this->assertEquals('Neustadt', $res['city']);
     $this->assertTrue(!isset($res['lat']) && !isset($res['lng']));
 }
 /**
  * @return void
  */
 public function testRecursive()
 {
     $result = $this->Addresses->find()->contain([$this->Users->alias(), $this->Comments->alias()])->first();
     $hashid = 'jR';
     $this->assertSame($hashid, $result->id);
     $this->assertSame(1, $result->comments[0]->id);
     $this->assertSame(1, $result->user->id);
     $this->Addresses->behaviors()->Hashid->config('recursive', true);
     $result = $this->Addresses->find()->contain([$this->Users->alias(), $this->Comments->alias()])->first();
     $hashid = 'jR';
     $this->assertSame($hashid, $result->id);
     $this->assertSame($hashid, $result->comments[0]->id);
     $this->assertSame($hashid, $result->user->id);
 }