AllTests.php 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. <?php
  2. /**
  3. * Zend Framework
  4. *
  5. * LICENSE
  6. *
  7. * This source file is subject to the new BSD license that is bundled
  8. * with this package in the file LICENSE.txt.
  9. * It is also available through the world-wide-web at this URL:
  10. * http://framework.zend.com/license/new-bsd
  11. * If you did not receive a copy of the license and are unable to
  12. * obtain it through the world-wide-web, please send an email
  13. * to license@zend.com so we can send you a copy immediately.
  14. *
  15. * @category Zend
  16. * @package Zend_Service_Amazon
  17. * @subpackage UnitTests
  18. * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
  19. * @license http://framework.zend.com/license/new-bsd New BSD License
  20. * @version $Id$
  21. */
  22. require_once dirname(dirname(dirname(dirname(__FILE__)))) . DIRECTORY_SEPARATOR . 'TestHelper.php';
  23. if (!defined('PHPUnit_MAIN_METHOD')) {
  24. define('PHPUnit_MAIN_METHOD', 'Zend_Service_Amazon_AllTests::main');
  25. }
  26. require_once 'Zend/Service/Amazon/OfflineTest.php';
  27. require_once 'Zend/Service/Amazon/OnlineTest.php';
  28. require_once 'Zend/Service/Amazon/Ec2/AllTests.php';
  29. require_once 'Zend/Service/Amazon/S3/AllTests.php';
  30. require_once 'Zend/Service/Amazon/SimpleDb/AllTests.php';
  31. require_once 'Zend/Service/Amazon/Sqs/AllTests.php';
  32. require_once 'Zend/Service/Amazon/Authentication/AllTests.php';
  33. /**
  34. * @category Zend
  35. * @package Zend_Service_Amazon
  36. * @subpackage UnitTests
  37. * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
  38. * @license http://framework.zend.com/license/new-bsd New BSD License
  39. * @group Zend_Service
  40. * @group Zend_Service_Amazon
  41. */
  42. class Zend_Service_Amazon_AllTests
  43. {
  44. /**
  45. * Runs this test suite
  46. *
  47. * @return void
  48. */
  49. public static function main()
  50. {
  51. PHPUnit_TextUI_TestRunner::run(self::suite());
  52. }
  53. /**
  54. * Creates and returns this test suite
  55. *
  56. * @return PHPUnit_Framework_TestSuite
  57. */
  58. public static function suite()
  59. {
  60. $suite = new PHPUnit_Framework_TestSuite('Zend Framework - Zend_Service_Amazon');
  61. $suite->addTestSuite('Zend_Service_Amazon_OfflineTest');
  62. if (defined('TESTS_ZEND_SERVICE_AMAZON_ONLINE_ENABLED') &&
  63. constant('TESTS_ZEND_SERVICE_AMAZON_ONLINE_ENABLED') &&
  64. defined('TESTS_ZEND_SERVICE_AMAZON_ONLINE_ACCESSKEYID')) {
  65. $suite->addTestSuite('Zend_Service_Amazon_OnlineTest');
  66. } else {
  67. $suite->addTestSuite('Zend_Service_Amazon_OnlineTest_Skip');
  68. }
  69. $suite->addTest(Zend_Service_Amazon_Authentication_AllTests::suite());
  70. $suite->addTest(Zend_Service_Amazon_Ec2_AllTests::suite());
  71. $suite->addTest(Zend_Service_Amazon_S3_AllTests::suite());
  72. $suite->addTest(Zend_Service_Amazon_SimpleDb_AllTests::suite());
  73. $suite->addTest(Zend_Service_Amazon_Sqs_AllTests::suite());
  74. return $suite;
  75. }
  76. }
  77. if (PHPUnit_MAIN_METHOD == 'Zend_Service_Amazon_AllTests::main') {
  78. Zend_Service_Amazon_AllTests::main();
  79. }