/** * @covers Moontoast\Math\BigNumber::compareTo */ public function testCompareTo() { $bn1 = new BigNumber('9223372036854775808'); $bn2 = new BigNumber(2147483647); $this->assertEquals(0, $bn1->compareTo('9223372036854775808')); $this->assertEquals(0, $bn2->compareTo(2147483647)); $this->assertEquals(1, $bn1->compareTo($bn2)); $this->assertEquals(-1, $bn2->compareTo($bn1)); }