Skip to content

Commit 0d0e683

Browse files
committed
MAGETWO-59089: Problem with change currency
- Added unit test for the method getCacheLifeTime()
1 parent 558b8cf commit 0d0e683

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

lib/internal/Magento/Framework/Pricing/Test/Unit/Render/PriceBoxTest.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,4 +241,16 @@ public function testGetRendererPool()
241241
{
242242
$this->assertEquals($this->rendererPool, $this->model->getRendererPool());
243243
}
244+
245+
/**
246+
* This tests the protected method getCacheLifeTime()
247+
*/
248+
public function testCacheLifeTime()
249+
{
250+
$reflectionClass = new \ReflectionClass(get_class($this->model));
251+
$methodReflection = $reflectionClass->getMethod('getCacheLifetime');
252+
$methodReflection->setAccessible(true);
253+
$cacheLifeTime = $methodReflection->invoke($this->model);
254+
$this->assertNull($cacheLifeTime, 'Expected null cache lifetime');
255+
}
244256
}

0 commit comments

Comments
 (0)