/** * @depends testGetSub */ public function testGetProperty($cateId) { $postage = new Product(Config::get()); $response = $postage->getProperty($cateId); $this->assertTrue(is_array($response)); return $response; }
/** * @param $name * @param array $products * @param Money $price */ public function __construct($name, array $products, Money $price = null) { $this->setProducts($products); parent::__construct($name, $price ?: $this->totalPrice(), $this->totalWeight()); }
public function __construct($name, Money $price) { parent::__construct($name, $price, new Weight(0)); }