minor #20043 @expectedException expects FQCN (ro0NL)

This PR was merged into the 2.8 branch.

Discussion
----------

@expectedException expects FQCN

| Q             | A
| ------------- | ---
| Branch?       | 2.8
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | comma-separated list of tickets fixed by the PR, if any
| License       | MIT
| Doc PR        | reference to the documentation PR, if any

See #20028

Almost there :)

Commits
-------

526b852 expectedException expects FQCN
This commit is contained in:
Fabien Potencier 2016-09-24 08:56:11 -07:00
commit 732a363f21
8 changed files with 13 additions and 13 deletions

View File

@ -176,7 +176,7 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
} }
/** /**
* @expectedException Symfony\Component\Console\Exception\CommandNotFoundException * @expectedException \Symfony\Component\Console\Exception\CommandNotFoundException
* @expectedExceptionMessage The command "foofoo" does not exist. * @expectedExceptionMessage The command "foofoo" does not exist.
*/ */
public function testGetInvalidCommand() public function testGetInvalidCommand()
@ -212,7 +212,7 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
} }
/** /**
* @expectedException Symfony\Component\Console\Exception\CommandNotFoundException * @expectedException \Symfony\Component\Console\Exception\CommandNotFoundException
* @expectedExceptionMessage The namespace "f" is ambiguous (foo, foo1). * @expectedExceptionMessage The namespace "f" is ambiguous (foo, foo1).
*/ */
public function testFindAmbiguousNamespace() public function testFindAmbiguousNamespace()
@ -225,7 +225,7 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
} }
/** /**
* @expectedException Symfony\Component\Console\Exception\CommandNotFoundException * @expectedException \Symfony\Component\Console\Exception\CommandNotFoundException
* @expectedExceptionMessage There are no commands defined in the "bar" namespace. * @expectedExceptionMessage There are no commands defined in the "bar" namespace.
*/ */
public function testFindInvalidNamespace() public function testFindInvalidNamespace()
@ -235,7 +235,7 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
} }
/** /**
* @expectedException Symfony\Component\Console\Exception\CommandNotFoundException * @expectedException \Symfony\Component\Console\Exception\CommandNotFoundException
* @expectedExceptionMessage Command "foo1" is not defined * @expectedExceptionMessage Command "foo1" is not defined
*/ */
public function testFindUniqueNameButNamespaceName() public function testFindUniqueNameButNamespaceName()
@ -313,7 +313,7 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
/** /**
* @dataProvider provideInvalidCommandNamesSingle * @dataProvider provideInvalidCommandNamesSingle
* @expectedException Symfony\Component\Console\Exception\CommandNotFoundException * @expectedException \Symfony\Component\Console\Exception\CommandNotFoundException
* @expectedExceptionMessage Did you mean this * @expectedExceptionMessage Did you mean this
*/ */
public function testFindAlternativeExceptionMessageSingle($name) public function testFindAlternativeExceptionMessageSingle($name)
@ -463,7 +463,7 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
} }
/** /**
* @expectedException Symfony\Component\Console\Exception\CommandNotFoundException * @expectedException \Symfony\Component\Console\Exception\CommandNotFoundException
* @expectedExceptionMessage Command "foo::bar" is not defined. * @expectedExceptionMessage Command "foo::bar" is not defined.
*/ */
public function testFindWithDoubleColonInNameThrowsException() public function testFindWithDoubleColonInNameThrowsException()

View File

@ -257,7 +257,7 @@ class CommandTest extends \PHPUnit_Framework_TestCase
} }
/** /**
* @expectedException Symfony\Component\Console\Exception\InvalidOptionException * @expectedException \Symfony\Component\Console\Exception\InvalidOptionException
* @expectedExceptionMessage The "--bar" option does not exist. * @expectedExceptionMessage The "--bar" option does not exist.
*/ */
public function testRunWithInvalidOption() public function testRunWithInvalidOption()

View File

@ -632,7 +632,7 @@ TABLE;
} }
/** /**
* @expectedException Symfony\Component\Console\Exception\InvalidArgumentException * @expectedException \Symfony\Component\Console\Exception\InvalidArgumentException
* @expectedExceptionMessage Style "absent" is not defined. * @expectedExceptionMessage Style "absent" is not defined.
*/ */
public function testIsNotDefinedStyleException() public function testIsNotDefinedStyleException()

View File

@ -194,7 +194,7 @@ class DefinitionTest extends \PHPUnit_Framework_TestCase
/** /**
* @dataProvider invalidDeprecationMessageProvider * @dataProvider invalidDeprecationMessageProvider
* @expectedException Symfony\Component\DependencyInjection\Exception\InvalidArgumentException * @expectedException \Symfony\Component\DependencyInjection\Exception\InvalidArgumentException
*/ */
public function testSetDeprecatedWithInvalidDeprecationTemplate($message) public function testSetDeprecatedWithInvalidDeprecationTemplate($message)
{ {

View File

@ -68,7 +68,7 @@ class ChainDecoderTest extends \PHPUnit_Framework_TestCase
} }
/** /**
* @expectedException Symfony\Component\Serializer\Exception\RuntimeException * @expectedException \Symfony\Component\Serializer\Exception\RuntimeException
*/ */
public function testDecodeUnsupportedFormat() public function testDecodeUnsupportedFormat()
{ {

View File

@ -69,7 +69,7 @@ class ChainEncoderTest extends \PHPUnit_Framework_TestCase
} }
/** /**
* @expectedException Symfony\Component\Serializer\Exception\RuntimeException * @expectedException \Symfony\Component\Serializer\Exception\RuntimeException
*/ */
public function testEncodeUnsupportedFormat() public function testEncodeUnsupportedFormat()
{ {

View File

@ -57,7 +57,7 @@ class JsonDecodeTest extends \PHPUnit_Framework_TestCase
/** /**
* @requires function json_last_error_msg * @requires function json_last_error_msg
* @dataProvider decodeProviderException * @dataProvider decodeProviderException
* @expectedException Symfony\Component\Serializer\Exception\UnexpectedValueException * @expectedException \Symfony\Component\Serializer\Exception\UnexpectedValueException
*/ */
public function testDecodeWithException($value) public function testDecodeWithException($value)
{ {

View File

@ -50,7 +50,7 @@ class JsonEncodeTest extends \PHPUnit_Framework_TestCase
/** /**
* @requires function json_last_error_msg * @requires function json_last_error_msg
* @expectedException Symfony\Component\Serializer\Exception\UnexpectedValueException * @expectedException \Symfony\Component\Serializer\Exception\UnexpectedValueException
*/ */
public function testEncodeWithError() public function testEncodeWithError()
{ {