Пример #1
0
 /**
  * @test
  * @runInSeparateProcess
  */
 public function test_static_setters_and_getters()
 {
     $taggable = new Taggable();
     // Delimiter
     $this->assertEquals(',', $taggable->getTagsDelimiter());
     $taggable->setTagsDelimiter('#');
     $this->assertEquals('#', $taggable->getTagsDelimiter());
     // Model
     $this->assertEquals('Cartalyst\\Tags\\IlluminateTag', $taggable->getTagsModel());
     $taggable->setTagsModel('Foo');
     $this->assertEquals('Foo', $taggable->getTagsModel());
     // Slug generator
     $this->assertEquals('Illuminate\\Support\\Str::slug', $taggable->getSlugGenerator());
     $taggable->setSlugGenerator('Foo');
     $this->assertEquals('Foo', $taggable->getSlugGenerator());
 }