Ejemplo n.º 1
0
 /**
  * @param string     $expected The expected value, as a string.
  * @param BigInteger $actual   The BigInteger instance to test.
  */
 protected final function assertBigIntegerEquals($expected, $actual)
 {
     $this->assertInstanceOf(BigInteger::getNamespace(), $actual);
     $this->assertSame($expected, (string) $actual);
 }
Ejemplo n.º 2
0
 /**
  * @dataProvider providerMax
  *
  * @param array  $values The values to test.
  * @param string $max    The expected maximum value.
  */
 public function testMax(array $values, $max)
 {
     $result = call_user_func_array([BigInteger::getNamespace(), 'max'], $values);
     $this->assertBigIntegerEquals($max, $result);
 }