示例#1
0
 /**
  * @dataProvider firstProvider()
  */
 public function testFirst($expected, $str, $n, $encoding = null)
 {
     $result = S::first($str, $n, $encoding);
     $this->assertInternalType('string', $result);
     $this->assertEquals($expected, $result);
 }
示例#2
0
 public function first($string, $count)
 {
     return Stringy::first($string, $count);
 }