Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Sign in
Toggle navigation
S
Silex
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
common
Silex
Commits
c6b63758
Commit
c6b63758
authored
Jun 08, 2012
by
Chris Sedlmayr
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Some CS fixes in line with the Symfony2 standards
parent
8b7796f9
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
14 additions
and
10 deletions
+14
-10
src/Silex/Application.php
src/Silex/Application.php
+1
-1
src/Silex/ControllerProviderInterface.php
src/Silex/ControllerProviderInterface.php
+1
-1
src/Silex/ExceptionHandler.php
src/Silex/ExceptionHandler.php
+1
-1
src/Silex/ServiceProviderInterface.php
src/Silex/ServiceProviderInterface.php
+2
-2
src/Silex/Util/Compiler.php
src/Silex/Util/Compiler.php
+1
-1
src/Silex/WebTestCase.php
src/Silex/WebTestCase.php
+1
-1
tests/Silex/Tests/ErrorHandlerTest.php
tests/Silex/Tests/ErrorHandlerTest.php
+3
-0
tests/Silex/Tests/JsonTest.php
tests/Silex/Tests/JsonTest.php
+0
-1
tests/Silex/Tests/RouterTest.php
tests/Silex/Tests/RouterTest.php
+3
-2
tests/Silex/Tests/WebTestCaseTest.php
tests/Silex/Tests/WebTestCaseTest.php
+1
-0
No files found.
src/Silex/Application.php
View file @
c6b63758
...
...
@@ -605,7 +605,7 @@ class Application extends \Pimple implements HttpKernelInterface, EventSubscribe
/**
* {@inheritdoc}
*/
static
publ
ic
function
getSubscribedEvents
()
public
stat
ic
function
getSubscribedEvents
()
{
return
array
(
KernelEvents
::
REQUEST
=>
array
(
...
...
src/Silex/ControllerProviderInterface.php
View file @
c6b63758
...
...
@@ -25,5 +25,5 @@ interface ControllerProviderInterface
*
* @return ControllerCollection A ControllerCollection instance
*/
function
connect
(
Application
$app
);
public
function
connect
(
Application
$app
);
}
src/Silex/ExceptionHandler.php
View file @
c6b63758
...
...
@@ -32,7 +32,7 @@ class ExceptionHandler implements EventSubscriberInterface
/**
* {@inheritdoc}
*/
static
publ
ic
function
getSubscribedEvents
()
public
stat
ic
function
getSubscribedEvents
()
{
return
array
(
SilexEvents
::
ERROR
=>
array
(
'onSilexError'
,
-
255
));
}
...
...
src/Silex/ServiceProviderInterface.php
View file @
c6b63758
...
...
@@ -26,7 +26,7 @@ interface ServiceProviderInterface
*
* @param Application $app An Application instance
*/
function
register
(
Application
$app
);
public
function
register
(
Application
$app
);
/**
* Bootstraps the application.
...
...
@@ -35,5 +35,5 @@ interface ServiceProviderInterface
* and should be used for "dynamic" configuration (whenever
* a service must be requested).
*/
function
boot
(
Application
$app
);
public
function
boot
(
Application
$app
);
}
src/Silex/Util/Compiler.php
View file @
c6b63758
...
...
@@ -160,7 +160,7 @@ EOF;
*
* @return string The PHP string with the whitespace removed
*/
static
publ
ic
function
stripWhitespace
(
$source
)
public
stat
ic
function
stripWhitespace
(
$source
)
{
if
(
!
function_exists
(
'token_get_all'
))
{
return
$source
;
...
...
src/Silex/WebTestCase.php
View file @
c6b63758
...
...
@@ -43,7 +43,7 @@ abstract class WebTestCase extends \PHPUnit_Framework_TestCase
/**
* Creates a Client.
*
* @param array $server
An array of server parameters
* @param array $server An array of server parameters
*
* @return Client A Client instance
*/
...
...
tests/Silex/Tests/ErrorHandlerTest.php
View file @
c6b63758
...
...
@@ -273,6 +273,7 @@ class ErrorHandlerTest extends \PHPUnit_Framework_TestCase
// Since we throw a standard Exception above only
// the second error handler should fire
$app
->
error
(
function
(
\LogicException
$e
)
{
// Extends \Exception
return
"Caught LogicException"
;
});
$app
->
error
(
function
(
\Exception
$e
)
{
...
...
@@ -298,6 +299,7 @@ class ErrorHandlerTest extends \PHPUnit_Framework_TestCase
// Since we throw a LogicException above
// the first error handler should fire
$app
->
error
(
function
(
\LogicException
$e
)
{
// Extends \Exception
return
"Caught LogicException"
;
});
$app
->
error
(
function
(
\Exception
$e
)
{
...
...
@@ -328,6 +330,7 @@ class ErrorHandlerTest extends \PHPUnit_Framework_TestCase
return
"Caught Exception"
;
});
$app
->
error
(
function
(
\LogicException
$e
)
{
// Extends \Exception
return
"Caught LogicException"
;
});
...
...
tests/Silex/Tests/JsonTest.php
View file @
c6b63758
...
...
@@ -13,7 +13,6 @@ namespace Silex\Tests;
use
Silex\Application
;
/**
* JSON test cases.
*
...
...
tests/Silex/Tests/RouterTest.php
View file @
c6b63758
...
...
@@ -146,7 +146,8 @@ class RouterTest extends \PHPUnit_Framework_TestCase
$this
->
checkRouteResponse
(
$app
,
'/resource'
,
'delete resource'
,
'delete'
);
}
public
function
testRequestShouldBeStoredRegardlessOfRouting
()
{
public
function
testRequestShouldBeStoredRegardlessOfRouting
()
{
$app
=
new
Application
();
$app
->
get
(
'/foo'
,
function
()
use
(
$app
)
{
...
...
@@ -240,7 +241,7 @@ class MyController
return
'foo'
;
}
static
publ
ic
function
getBar
()
public
stat
ic
function
getBar
()
{
return
'bar'
;
}
...
...
tests/Silex/Tests/WebTestCaseTest.php
View file @
c6b63758
...
...
@@ -36,6 +36,7 @@ class WebTestCaseTest extends WebTestCase
$app
->
match
(
'/server'
,
function
()
use
(
$app
)
{
$user
=
$app
[
'request'
]
->
server
->
get
(
'PHP_AUTH_USER'
);
$pass
=
$app
[
'request'
]
->
server
->
get
(
'PHP_AUTH_PW'
);
return
"<h1>
$user
:
$pass
</h1>"
;
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment