removed usage of the deprecated forms of asset() in the core framework

This commit is contained in:
Fabien Potencier 2015-02-10 13:56:33 +01:00
parent f74a1f2dc3
commit 0750d02025
3 changed files with 3 additions and 6 deletions

View File

@ -1,7 +1,7 @@
{% extends 'TwigBundle::layout.html.twig' %}
{% block head %}
<link href="{{ asset('bundles/framework/css/exception.css', absolute=true) }}" rel="stylesheet" type="text/css" media="all" />
<link href="{{ absolute_url(asset('bundles/framework/css/exception.css')) }}" rel="stylesheet" type="text/css" media="all" />
{% endblock %}
{% block title %}

View File

@ -4,8 +4,8 @@
<meta charset="{{ _charset }}" />
<meta name="robots" content="noindex,nofollow" />
<title>{% block title %}{% endblock %}</title>
<link href="{{ asset('bundles/framework/css/structure.css', absolute=true) }}" rel="stylesheet" />
<link href="{{ asset('bundles/framework/css/body.css', absolute=true) }}" rel="stylesheet" />
<link href="{{ absolute_url(asset('bundles/framework/css/structure.css')) }}" rel="stylesheet" />
<link href="{{ absolute_url(asset('bundles/framework/css/body.css')) }}" rel="stylesheet" />
{% block head %}{% endblock %}
</head>
<body>

View File

@ -52,9 +52,6 @@ class WebProfilerExtensionTest extends TestCase
$this->container->addScope(new Scope('request'));
$this->container->register('request', 'Symfony\\Component\\HttpFoundation\\Request')->setScope('request');
$this->container->register('router', $this->getMockClass('Symfony\\Component\\Routing\\RouterInterface'));
$this->container->register('templating.helper.assets', $this->getMockClass('Symfony\\Component\\Templating\\Helper\\AssetsHelper'));
$this->container->register('templating.helper.router', $this->getMockClass('Symfony\\Bundle\\FrameworkBundle\\Templating\\Helper\\RouterHelper'))
->addArgument(new Reference('router'));
$this->container->register('twig', 'Twig_Environment');
$this->container->setParameter('kernel.bundles', array());
$this->container->setParameter('kernel.cache_dir', __DIR__);