public function testStatesArray() { $config = $this->app['config']->get('expendable.state'); $result = \Distilleries\Expendable\Helpers\StaticLabel::states(); $this->assertTrue(is_array($result)); foreach ($config as $key => $value) { $this->assertArrayHasKey($key, $result); } }
public function buildForm() { $this->add('libelle', 'text', ['validation' => 'required', 'label' => trans('expendable::form.name'), 'help' => trans('expendable::form.auto_sufix')])->add('state', 'choice', ['choices' => StaticLabel::states(), 'empty_value' => '-', 'label' => trans('expendable::form.state'), 'expanded' => true, 'multiple' => true])->add('models', 'choice', ['choices' => $this->getChoiceModels(), 'empty_value' => '-', 'label' => trans('expendable::form.model')])->add('colon_datatable', 'tag', ['label' => trans('expendable::form.columns'), 'help' => trans('expendable::form.help_colon_datatable')])->add('fields_form', 'tag', ['label' => trans('expendable::form.fields'), 'help' => trans('expendable::form.help_fields_form')])->addDefaultActions(); }