diff --git a/library/Class/Template.php b/library/Class/Template.php
index 4c0deba2e59caa9d7850be8115f684f5e58bbff0..34762c2c971a4c283febca091d53a42abfa98357 100644
--- a/library/Class/Template.php
+++ b/library/Class/Template.php
@@ -732,7 +732,7 @@ class Class_Template {
 
 
   public function getFolder() : string {
-    return dirname((new ReflectionClass($this))->getFileName());
+    return basename(dirname((new ReflectionClass($this))->getFileName()));
   }
 
 
diff --git a/tests/scenarios/Templates/MyBibAppTemplateTest.php b/tests/scenarios/Templates/MyBibAppTemplateTest.php
index eb5b870e48c8aa065ab2d2b18f63d69dc32e2838..52645279b54b7e1c5042a642d8989d474bccdc9a 100644
--- a/tests/scenarios/Templates/MyBibAppTemplateTest.php
+++ b/tests/scenarios/Templates/MyBibAppTemplateTest.php
@@ -149,7 +149,6 @@ class MyBibAppTemplateOpacIndexWithUserAgentTest extends MyBibAppTemplateTestCas
     Class_AdminVar::set('MYBIBAPP_TEMPLATE', 1);
 
     Class_Profil::find(2)->beCurrentProfil();
-
     $this->dispatch('/opac/index/index');
   }
 
@@ -168,7 +167,10 @@ class MyBibAppTemplateOpacIndexWithUserAgentTest extends MyBibAppTemplateTestCas
 
   /** @test */
   public function pageShouldLoadMyBibAppCss() {
-    $this->assertXPath('//head/link[contains(@href, "/library/templates/MyBibApp/Assets/css/mybibapp.css")]');
+    $this->assertXPath(sprintf('//head/link[@href="%s/library/templates/MyBibApp/Assets/css/mybibapp.css?v=%s"]',
+                               BASE_URL,
+                               Class_ScriptLoader::getInstance()->getCacheHash()),
+                       $this->_response->getBody());
   }