activity_helperTest.php 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: stanley-king
  5. * Date: 16/8/14
  6. * Time: 下午5:29
  7. */
  8. define('BASE_ROOT_PATH',str_replace('/test','',dirname(__FILE__)));
  9. require_once(BASE_ROOT_PATH . '/fooder.php');
  10. require_once(BASE_ROOT_PATH . '/helper/activity_helper.php');
  11. require_once(BASE_ROOT_PATH . '/helper/goods_helper.php');
  12. class activity_helperTest extends PHPUnit_Framework_TestCase
  13. {
  14. public static function setUpBeforeClass()
  15. {
  16. Base::run_util();
  17. }
  18. public function testGift()
  19. {
  20. $helper = new goods_helper();
  21. // $helper->get_summary(array(1269,4127,4217));
  22. $helper->get_summary(array(1269));
  23. }
  24. public function testGroupbuy()
  25. {
  26. $activity = new activity_helper();
  27. $activity->groupbuy_list();
  28. }
  29. public function testXianshi()
  30. {
  31. $activity = new activity_helper();
  32. $activity->xianshi_list(6);
  33. }
  34. public function testMansong()
  35. {
  36. $activity = new activity_helper();
  37. $activity->mansong_list(6);
  38. }
  39. public function testBundling()
  40. {
  41. $activity = new activity_helper();
  42. $activity->bundling_list(6);
  43. }
  44. public function testBooth()
  45. {
  46. $activity = new activity_helper();
  47. $activity->booth_list(6);
  48. }
  49. public function testTakepart()
  50. {
  51. activity_helper::take_parted(30,$type);
  52. }
  53. }