File tree Expand file tree Collapse file tree 4 files changed +34
-4
lines changed Expand file tree Collapse file tree 4 files changed +34
-4
lines changed Original file line number Diff line number Diff line change 2
2
3
3
All notable changes to this project will be documented in this file, in reverse chronological order by release.
4
4
5
+ ## 3.0.0alpha7 - 2018-02-14
6
+
7
+ ### Added
8
+
9
+ - Nothing.
10
+
11
+ ### Changed
12
+
13
+ - [ #556 ] ( https://github.com/zendframework/zend-expressive/pull/556 ) modifies the
14
+ ` ApplicationFactory ` such that it now uses the
15
+ ` Zend\Expressive\ROUTE_MIDDLEWARE ` constant in order to retrieve the
16
+ ` Zend\Expressive\Router\Middleware\PathBasedRoutingMiddleware ` instance.
17
+ This is done to help smooth upgrades from v2 to v3, as it prevents a manual
18
+ step when updating the ` config/pipeline.php ` , and ensures that the instance
19
+ composed in the application is the same instance piped to the application.
20
+
21
+ ### Deprecated
22
+
23
+ - Nothing.
24
+
25
+ ### Removed
26
+
27
+ - Nothing.
28
+
29
+ ### Fixed
30
+
31
+ - Nothing.
32
+
5
33
## 3.0.0alpha6 - 2018-02-14
6
34
7
35
### Added
Original file line number Diff line number Diff line change 13
13
use Zend \Expressive \Application ;
14
14
use Zend \Expressive \ApplicationPipeline ;
15
15
use Zend \Expressive \MiddlewareFactory ;
16
- use Zend \Expressive \Router \Middleware \PathBasedRoutingMiddleware ;
17
16
use Zend \HttpHandlerRunner \RequestHandlerRunner ;
18
17
18
+ use const Zend \Expressive \ROUTE_MIDDLEWARE ;
19
+
19
20
/**
20
21
* Create an Application instance.
21
22
*
@@ -35,7 +36,7 @@ public function __invoke(ContainerInterface $container) : Application
35
36
return new Application (
36
37
$ container ->get (MiddlewareFactory::class),
37
38
$ container ->get (ApplicationPipeline::class),
38
- $ container ->get (PathBasedRoutingMiddleware::class ),
39
+ $ container ->get (ROUTE_MIDDLEWARE ),
39
40
$ container ->get (RequestHandlerRunner::class)
40
41
);
41
42
}
Original file line number Diff line number Diff line change 70
70
* Should resolve to the Zend\Expressive\Router\Middleware\PathBasedRoutingMiddleware
71
71
* service.
72
72
*
73
- * @deprecated To remove in version 4.0.0.
74
73
* @var string
75
74
*/
76
75
const ROUTE_MIDDLEWARE = __NAMESPACE__ . '\Middleware\RouteMiddleware ' ;
Original file line number Diff line number Diff line change 19
19
use Zend \HttpHandlerRunner \RequestHandlerRunner ;
20
20
use Zend \Stratigility \MiddlewarePipeInterface ;
21
21
22
+ use const Zend \Expressive \ROUTE_MIDDLEWARE ;
23
+
22
24
class ApplicationFactoryTest extends TestCase
23
25
{
24
26
public function testFactoryProducesAnApplication ()
@@ -31,7 +33,7 @@ public function testFactoryProducesAnApplication()
31
33
$ container = $ this ->prophesize (ContainerInterface::class);
32
34
$ container ->get (MiddlewareFactory::class)->willReturn ($ middlewareFactory );
33
35
$ container ->get (ApplicationPipeline::class)->willReturn ($ pipeline );
34
- $ container ->get (PathBasedRoutingMiddleware::class )->willReturn ($ routeMiddleware );
36
+ $ container ->get (ROUTE_MIDDLEWARE )->willReturn ($ routeMiddleware );
35
37
$ container ->get (RequestHandlerRunner::class)->willReturn ($ runner );
36
38
37
39
$ factory = new ApplicationFactory ();
You can’t perform that action at this time.
0 commit comments