示例#1
0
 public function test_lists_of_translated_fields_with_fallback()
 {
     App::make('config')->set('translatable.fallback_locale', 'en');
     App::setLocale('de');
     $country = new Country();
     $country->useTranslationFallback = true;
     $list = [['id' => '1', 'name' => 'Griechenland'], ['id' => '2', 'name' => 'France']];
     $this->assertEquals($list, $country->listsTranslations('name')->get()->toArray());
 }