Ejemplo n.º 1
0
 /**
  * This method tests the "eq" method.
  *
  * @dataProvider data_eq
  */
 public function test_eq(array $provided, array $expected)
 {
     $p0 = ITuple\Module::eq(ITuple\Type::make($provided[0], '\\Saber\\Data\\IInt32\\Type'), ITuple\Type::make($provided[1], '\\Saber\\Data\\IInt32\\Type'));
     $e0 = $expected[0];
     $this->assertInstanceOf('\\Saber\\Data\\IBool\\Type', $p0);
     $this->assertSame($e0, $p0->unbox());
 }
Ejemplo n.º 2
0
 /**
  * This method evaluates whether the left operand is NOT equal to the right operand.
  *
  * @access public
  * @static
  * @param ITuple\Type $xs                                   the left operand
  * @param Core\Type $ys                                     the right operand
  * @return IBool\Type                                       whether the left operand is NOT equal
  *                                                          to the right operand
  */
 public static function ne(ITuple\Type $xs, Core\Type $ys) : IBool\Type
 {
     // !=
     return IBool\Module::not(ITuple\Module::eq($xs, $ys));
 }