baseTest.php 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. // +----------------------------------------------------------------------
  3. // | ThinkPHP [ WE CAN DO IT JUST THINK ]
  4. // +----------------------------------------------------------------------
  5. // | Copyright (c) 2006~2016 http://thinkphp.cn All rights reserved.
  6. // +----------------------------------------------------------------------
  7. // | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
  8. // +----------------------------------------------------------------------
  9. // | Author: Haotong Lin <lofanmi@gmail.com>
  10. // +----------------------------------------------------------------------
  11. /**
  12. * 保证运行环境正常
  13. */
  14. class baseTest extends \PHPUnit_Framework_TestCase
  15. {
  16. public function testConstants()
  17. {
  18. $this->assertNotEmpty(THINK_START_TIME);
  19. $this->assertNotEmpty(THINK_START_MEM);
  20. $this->assertNotEmpty(THINK_VERSION);
  21. $this->assertNotEmpty(DS);
  22. $this->assertNotEmpty(THINK_PATH);
  23. $this->assertNotEmpty(LIB_PATH);
  24. $this->assertNotEmpty(EXTEND_PATH);
  25. $this->assertNotEmpty(CORE_PATH);
  26. $this->assertNotEmpty(TRAIT_PATH);
  27. $this->assertNotEmpty(APP_PATH);
  28. $this->assertNotEmpty(RUNTIME_PATH);
  29. $this->assertNotEmpty(LOG_PATH);
  30. $this->assertNotEmpty(CACHE_PATH);
  31. $this->assertNotEmpty(TEMP_PATH);
  32. $this->assertNotEmpty(VENDOR_PATH);
  33. $this->assertNotEmpty(EXT);
  34. $this->assertNotEmpty(ENV_PREFIX);
  35. $this->assertTrue(!is_null(IS_WIN));
  36. $this->assertTrue(!is_null(IS_CLI));
  37. }
  38. }