Changeset 22204 for branches/version-2_12-dev/tests
- Timestamp:
- 2013/01/06 17:36:52 (11 years ago)
- Location:
- branches/version-2_12-dev/tests/class
- Files:
-
- 6 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/version-2_12-dev/tests/class/helper/SC_Helper_Purchase/SC_Helper_Purchase_TestBase.php
r22203 r22204 47 47 protected function setUpShipping($shipping) { 48 48 if (!$shipping) { 49 $shipping = getSingleShipping();49 $shipping = $this->getSingleShipping(); 50 50 } 51 51 … … 85 85 $shippings = array( 86 86 array( 87 'update_date' => ' CURRENT_TIMESTAMP',87 'update_date' => '2000-01-01 00:00:00', 88 88 'shipping_id' => '1', 89 89 'order_id' => '1', … … 92 92 ), 93 93 array( 94 'update_date' => ' CURRENT_TIMESTAMP',94 'update_date' => '2000-01-01 00:00:00', 95 95 'shipping_id' => '2', 96 96 'order_id' => '2', … … 99 99 ), 100 100 array( 101 'update_date' => ' CURRENT_TIMESTAMP',101 'update_date' => '2000-01-01 00:00:00', 102 102 'shipping_id' => '1002', 103 103 'order_id' => '1002', … … 147 147 $product_class = array( 148 148 array( 149 'update_date' => ' CURRENT_TIMESTAMP',149 'update_date' => '2000-01-01 00:00:00', 150 150 'product_class_id' => '1001', 151 151 'product_id' => '1001', … … 160 160 ), 161 161 array( 162 'update_date' => ' CURRENT_TIMESTAMP',162 'update_date' => '2000-01-01 00:00:00', 163 163 'product_class_id' => '1002', 164 164 'product_id' => '1002', … … 184 184 $class_category = array( 185 185 array( 186 'update_date' => ' CURRENT_TIMESTAMP',186 'update_date' => '2000-01-01 00:00:00', 187 187 'classcategory_id' => '1001', 188 188 'class_id' => '1', … … 191 191 ), 192 192 array( 193 'update_date' => ' CURRENT_TIMESTAMP',193 'update_date' => '2000-01-01 00:00:00', 194 194 'classcategory_id' => '1002', 195 195 'class_id' => '1', … … 211 211 $products = array( 212 212 array( 213 'update_date' => ' CURRENT_TIMESTAMP',213 'update_date' => '2000-01-01 00:00:00', 214 214 'product_id' => '1001', 215 215 'name' => '製品名1001', … … 219 219 ), 220 220 array( 221 'update_date' => ' CURRENT_TIMESTAMP',221 'update_date' => '2000-01-01 00:00:00', 222 222 'product_id' => '1002', 223 223 'name' => '製品名1002', … … 299 299 'creator_id' => '1', 300 300 'del_flg' => '1', 301 'update_date' => ' CURRENT_TIMESTAMP'301 'update_date' => '2000-01-01 00:00:00' 302 302 ), 303 303 array( … … 307 307 'creator_id' => '1', 308 308 'rank' => '2', 309 'update_date' => ' CURRENT_TIMESTAMP'309 'update_date' => '2000-01-01 00:00:00' 310 310 ), 311 311 array( … … 315 315 'creator_id' => '1', 316 316 'rank' => '3', 317 'update_date' => ' CURRENT_TIMESTAMP'317 'update_date' => '2000-01-01 00:00:00' 318 318 ), 319 319 array( // 商品種別違い … … 323 323 'creator_id' => '1', 324 324 'rank' => '4', 325 'update_date' => ' CURRENT_TIMESTAMP'325 'update_date' => '2000-01-01 00:00:00' 326 326 ), 327 327 ); … … 367 367 $payment = array( 368 368 array( 369 'update_date' => ' CURRENT_TIMESTAMP',369 'update_date' => '2000-01-01 00:00:00', 370 370 'payment_id' => '1001', 371 371 'creator_id' => '1', … … 373 373 ), 374 374 array( 375 'update_date' => ' CURRENT_TIMESTAMP',375 'update_date' => '2000-01-01 00:00:00', 376 376 'payment_id' => '1002', 377 377 'creator_id' => '1', … … 380 380 ), 381 381 array( 382 'update_date' => ' CURRENT_TIMESTAMP',382 'update_date' => '2000-01-01 00:00:00', 383 383 'payment_id' => '1003', 384 384 'creator_id' => '1', … … 386 386 ), 387 387 array( 388 'update_date' => ' CURRENT_TIMESTAMP',388 'update_date' => '2000-01-01 00:00:00', 389 389 'payment_id' => '3001', 390 390 'creator_id' => '1', … … 393 393 ), 394 394 array( 395 'update_date' => ' CURRENT_TIMESTAMP',395 'update_date' => '2000-01-01 00:00:00', 396 396 'payment_id' => '3002', 397 397 'creator_id' => '1', … … 399 399 ), 400 400 array( 401 'update_date' => ' CURRENT_TIMESTAMP',401 'update_date' => '2000-01-01 00:00:00', 402 402 'payment_id' => '3003', 403 403 'creator_id' => '1', … … 406 406 ), 407 407 array( 408 'update_date' => ' CURRENT_TIMESTAMP',408 'update_date' => '2000-01-01 00:00:00', 409 409 'payment_id' => '3004', 410 410 'creator_id' => '1', … … 413 413 ), 414 414 array( 415 'update_date' => ' CURRENT_TIMESTAMP',415 'update_date' => '2000-01-01 00:00:00', 416 416 'payment_id' => '3005', 417 417 'creator_id' => '1', … … 434 434 $order = array( 435 435 array( 436 'update_date' => ' CURRENT_TIMESTAMP',436 'update_date' => '2000-01-01 00:00:00', 437 437 'order_id' => '1001', 438 438 'customer_id' => '1001', 439 439 'order_name01' => '受注情報01', 440 440 'status' => '3', 441 'payment_date' => '2032-12-31 01:20:30' // 日付が変わっても良いように、遠い未来に設定 441 'payment_date' => '2032-12-31 01:20:30', // 日付が変わっても良いように、遠い未来に設定 442 'use_point' => '10', 443 'add_point' => '20' 442 444 ), 443 445 array( 444 'update_date' => ' CURRENT_TIMESTAMP',446 'update_date' => '2000-01-01 00:00:00', 445 447 'order_id' => '1002', 446 448 'customer_id' => '1002', 447 449 'order_name01' => '受注情報02', 450 'status' => '5', 448 451 'payment_id' => '1002', 449 452 'payment_method' => '支払方法1001', 450 'deliv_id' => '1002' 453 'deliv_id' => '1002', 454 'use_point' => '10', 455 'add_point' => '20' 451 456 ) 452 457 ); … … 464 469 $order = array( 465 470 array( 466 'update_date' => ' CURRENT_TIMESTAMP',471 'update_date' => '2000-01-01 00:00:00', 467 472 'order_temp_id' => '1001', 468 473 'customer_id' => '1001', 469 'order_name01' => '受注情報01' 474 'order_name01' => '受注情報01', 475 'order_id' => '1001' 470 476 ), 471 477 array( 472 'update_date' => ' CURRENT_TIMESTAMP',478 'update_date' => '2000-01-01 00:00:00', 473 479 'order_temp_id' => '1002', 474 480 'customer_id' => '1002', … … 535 541 } 536 542 543 /** 544 * DBに顧客情報を設定します。 545 */ 546 protected function setUpCustomer() { 547 $customer = array( 548 array( 549 'customer_id' => '1001', 550 'name01' => '苗字', 551 'name02' => '名前', 552 'kana01' => 'みょうじ', 553 'kana02' => 'なまえ', 554 'email' => 'test@example.com', 555 'secret_key' => 'hoge', 556 'point' => '100', 557 'update_date' => '2000-01-01 00:00:00' 558 ), 559 array( 560 'customer_id' => '1002', 561 'name01' => '苗字2', 562 'name02' => '名前2', 563 'kana01' => 'みょうじ2', 564 'kana02' => 'なまえ2', 565 'email' => 'test2@example.com', 566 'secret_key' => 'hoge2', 567 'point' => '200', 568 'update_date' => '2000-01-01 00:00:00' 569 ) 570 ); 571 572 $this->objQuery->delete('dtb_customer'); 573 foreach ($customer as $item) { 574 $this->objQuery->insert('dtb_customer', $item); 575 } 576 } 577 537 578 } 538 579 -
branches/version-2_12-dev/tests/class/helper/SC_Helper_Purchase/SC_Helper_Purchase_saveOrderTempTest.php
r22202 r22204 38 38 parent::setUp(); 39 39 $this->setUpOrderTemp(); 40 $this->helper = new SC_Helper_Purchase_ Mock();40 $this->helper = new SC_Helper_Purchase_saveOrderTempMock(); 41 41 } 42 42 … … 135 135 } 136 136 137 class SC_Helper_Purchase_ Mock extends SC_Helper_Purchase {137 class SC_Helper_Purchase_saveOrderTempMock extends SC_Helper_Purchase { 138 138 function copyFromCustomer($sqlval, $objCustomer) { 139 139 echo('COPY_FROM_CUSTOMER'); -
branches/version-2_12-dev/tests/class/util/SC_Utils/SC_Utils_sfPrintRTest.php
r22193 r22204 44 44 45 45 ///////////////////////////////////////// 46 // TODO 環境により出力形式が異なるため、テスト不可(デバッグ用なので、テストしなくてもよさそう) 47 /** 46 48 public function testSfPrintR__指定したオブジェクトの情報が出力される() { 47 49 $output = '<div style="font-size: 12px;color: #00FF00;">' . "\n" … … 58 60 SC_Utils::sfPrintR(array('test'=>'TEST')); 59 61 } 60 62 */ 61 63 ////////////////////////////////////////// 62 64
Note: See TracChangeset
for help on using the changeset viewer.