container); $users = array( array( 'id' => 1, 'username' => 'someone', 'name' => 'Someone', 'email' => 'test@localhost', 'avatar_path' => 'avatar_image', ), array( 'id' => 2, 'username' => 'somebody', 'name' => '', 'email' => '', 'avatar_path' => '', ) ); $expected = array( array( 'value' => 'someone', 'html' => '
Someone
someone Someone', ), array( 'value' => 'somebody', 'html' => '
S
somebody', ), ); $this->assertSame($expected, $userMentionFormatter->withUsers($users)->format()); } }