Skip to content

Commit 556baf0

Browse files
author
Sergey Danilchenko
committed
add test
1 parent 8364647 commit 556baf0

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tests/Knp/Menu/Tests/Twig/MenuExtensionTest.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,14 @@ public function testGetCurrentItem(): void
163163
$this->assertEquals('current', $this->getTemplate('{{ knp_menu_get_current_item("default") is knp_menu_current ? "current" : "not current" }}', $helper, $matcher)->render([]));
164164
}
165165

166+
public function testLastModified(): void
167+
{
168+
$this->assertSame(max(
169+
filemtime((new \ReflectionClass(MenuExtension::class))->getFileName()),
170+
filemtime((new \ReflectionClass(MenuRuntimeExtension::class))->getFileName()),
171+
), (new MenuExtension())->getLastModified());
172+
}
173+
166174
/**
167175
* @param array<string> $methods
168176
*/

0 commit comments

Comments
 (0)