source: branches/version-2_13-dev/tests/class/SC_Product/SC_Product_findProductCountTest.php @ 22960

Revision 22960, 1.2 KB checked in by Seasoft, 9 years ago (diff)

#2043 (typo修正・ソース整形・ソースコメントの改善 for 2.13.0)

  • 語句統一「全て」
Line 
1<?php
2
3$HOME = realpath(dirname(__FILE__)) . "/../../..";
4require_once($HOME . "/tests/class/SC_Product/SC_Product_TestBase.php");
5/**
6 *
7 */
8class SC_Product_findProductCountTest extends SC_Product_TestBase
9{
10
11    protected function setUp()
12    {
13        parent::setUp();
14        $this->objProducts = new SC_Product_Ex();
15    }
16
17    protected function tearDown()
18    {
19        parent::tearDown();
20    }
21
22    /////////////////////////////////////////
23
24    public function testFindProductCount_全ての商品数を返す()
25    {
26        $this->setUpProductClass();
27        $this->setUpProducts();
28        $this->setUpClassCategory();
29
30        $this->expected = 3;
31
32        $this->actual = $this->objProducts->findProductCount($this->objQuery);
33
34        $this->verify('商品数');
35    }
36   
37    public function testFindProductCount_検索条件に一致する商品数を返す()
38    {
39        $this->setUpProductClass();
40        $this->setUpProducts();
41        $this->setUpClassCategory();
42       
43        $this->objQuery->setWhere('product_id = ?');
44        $arrVal = array(1001);
45
46        $this->expected = 1;
47
48        $this->actual = $this->objProducts->findProductCount($this->objQuery, $arrVal);
49
50        $this->verify('検索商品数');
51    }
52   
53}
Note: See TracBrowser for help on using the repository browser.