public function testConcatenatedSlug() { $post = new SluggablePost(); $post->title = 'Sweetness and Light'; $post->description = 'Itchee and Scratchee'; $post->save(); $this->assertEquals('sweetness-and-light-itchee-and-scratchee', $post->long_slug); }
public function testSetSlugAttributeManually() { $post = new SluggablePost(); $post->title = 'We parked in a comfortable spot'; $post->slug = 'war-is-pain'; $post->save(); $this->assertEquals('war-is-pain', $post->slug); }