Example #1
0
 public function testGetUserResponsible()
 {
     $post = new Post();
     $post->title = 'Testing';
     $post->description = 'Testing';
     $post->save();
     $post->user_id = $this->user->id;
     $post->save();
     $revisions = $post->revisions;
     $user = $revisions->get(0)->getUserResponsible();
     $this->assertEquals(1, $user->id);
     $this->assertEquals('User One', $user->username);
 }