Ejemplo n.º 1
0
 public function testGetProductPortletTotalPrice()
 {
     $super = User::getByUsername('super');
     Yii::app()->user->userModel = $super;
     $product = ProductTestHelper::createProductByNameForOwner('My Product 1', $super);
     $id = $product->id;
     $product->forget();
     unset($product);
     $product = Product::getById($id);
     $totalPrice = ProductElementUtil::getProductPortletTotalPrice($product, 0);
     $this->assertEquals($totalPrice, "\$1,001.08");
     // Not Coding Standard
 }