DataTest.php 958 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. /**
  7. * Test class for \Magento\PageCache\Helper\Data
  8. */
  9. namespace Magento\PageCache\Test\Unit\Helper;
  10. /**
  11. * Class DataTest
  12. *
  13. */
  14. class DataTest extends \PHPUnit\Framework\TestCase
  15. {
  16. /**
  17. * @var Data
  18. */
  19. protected $helper;
  20. /**
  21. * @var \Magento\Framework\View\Layout\ProcessorInterface|\PHPUnit_Framework_MockObject_MockObject
  22. */
  23. protected $updateLayoutMock;
  24. /**
  25. * @var \Magento\Framework\App\Helper\Context|\PHPUnit_Framework_MockObject_MockObject
  26. */
  27. protected $contextMock;
  28. /**
  29. * @var \Magento\Framework\App\View|\PHPUnit_Framework_MockObject_MockObject
  30. */
  31. protected $viewMock;
  32. public function testMaxAgeCache()
  33. {
  34. // one year
  35. $age = 365 * 24 * 60 * 60;
  36. $this->assertEquals($age, \Magento\PageCache\Helper\Data::PRIVATE_MAX_AGE_CACHE);
  37. }
  38. }