create(); $post = Post::factory()->create(); $comment = Comment::factory()->create([ 'commentable_id' => $post->id, 'commentable_type' => $post->getMorphClass(), 'commenter_id' => $user->getKey(), 'commenter_type' => $user->getMorphClass(), 'body' => '

Hello

', ]); expect($comment->body)->not->toContain('', ]); $comment->refresh(); expect($comment->body)->not->toContain('') ->call('addComment'); $comment = Comment::first(); expect($comment->body)->not->toContain('