You are here

class FileValidatorPathTest in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/validator/Tests/Constraints/FileValidatorPathTest.php \Symfony\Component\Validator\Tests\Constraints\FileValidatorPathTest

Hierarchy

Expanded class hierarchy of FileValidatorPathTest

File

vendor/symfony/validator/Tests/Constraints/FileValidatorPathTest.php, line 16

Namespace

Symfony\Component\Validator\Tests\Constraints
View source
class FileValidatorPathTest extends FileValidatorTest {
  protected function getFile($filename) {
    return $filename;
  }
  public function testFileNotFound() {
    $constraint = new File(array(
      'notFoundMessage' => 'myMessage',
    ));
    $this->validator
      ->validate('foobar', $constraint);
    $this
      ->buildViolation('myMessage')
      ->setParameter('{{ file }}', '"foobar"')
      ->setCode(File::NOT_FOUND_ERROR)
      ->assertRaised();
  }

}

Members

Namesort descending Modifiers Type Description Overrides
AbstractConstraintValidatorTest::$constraint protected property
AbstractConstraintValidatorTest::$context protected property 1
AbstractConstraintValidatorTest::$defaultTimezone protected property
AbstractConstraintValidatorTest::$group protected property
AbstractConstraintValidatorTest::$metadata protected property
AbstractConstraintValidatorTest::$object protected property
AbstractConstraintValidatorTest::$propertyPath protected property
AbstractConstraintValidatorTest::$root protected property
AbstractConstraintValidatorTest::$validator protected property 1
AbstractConstraintValidatorTest::$value protected property
AbstractConstraintValidatorTest::assertNoViolation protected function
AbstractConstraintValidatorTest::assertViolation Deprecated protected function
AbstractConstraintValidatorTest::assertViolations Deprecated protected function
AbstractConstraintValidatorTest::buildViolation protected function
AbstractConstraintValidatorTest::createContext protected function
AbstractConstraintValidatorTest::createViolation Deprecated protected function
AbstractConstraintValidatorTest::expectNoValidate protected function
AbstractConstraintValidatorTest::expectValidateAt protected function
AbstractConstraintValidatorTest::expectValidateValueAt protected function
AbstractConstraintValidatorTest::restoreDefaultTimezone protected function
AbstractConstraintValidatorTest::setDefaultTimezone protected function
AbstractConstraintValidatorTest::setGroup protected function
AbstractConstraintValidatorTest::setObject protected function
AbstractConstraintValidatorTest::setProperty protected function
AbstractConstraintValidatorTest::setPropertyPath protected function
AbstractConstraintValidatorTest::setRoot protected function
AbstractConstraintValidatorTest::setValue protected function
FileValidatorPathTest::getFile protected function Overrides FileValidatorTest::getFile
FileValidatorPathTest::testFileNotFound public function
FileValidatorTest::$file protected property
FileValidatorTest::$path protected property
FileValidatorTest::createValidator protected function Overrides AbstractConstraintValidatorTest::createValidator
FileValidatorTest::getApiVersion protected function Overrides AbstractConstraintValidatorTest::getApiVersion
FileValidatorTest::provideBinaryFormatTests public function
FileValidatorTest::provideMaxSizeExceededTests public function
FileValidatorTest::provideMaxSizeNotExceededTests public function
FileValidatorTest::setUp protected function Overrides AbstractConstraintValidatorTest::setUp
FileValidatorTest::tearDown protected function Overrides AbstractConstraintValidatorTest::tearDown
FileValidatorTest::testBinaryFormat public function @dataProvider provideBinaryFormatTests
FileValidatorTest::testDisallowEmpty public function
FileValidatorTest::testEmptyStringIsValid public function
FileValidatorTest::testExpectsStringCompatibleTypeOrFile public function @expectedException \Symfony\Component\Validator\Exception\UnexpectedTypeException
FileValidatorTest::testInvalidMaxSize public function @expectedException \Symfony\Component\Validator\Exception\ConstraintDefinitionException
FileValidatorTest::testInvalidMimeType public function
FileValidatorTest::testInvalidWildcardMimeType public function
FileValidatorTest::testMaxSizeExceeded public function @dataProvider provideMaxSizeExceededTests
FileValidatorTest::testMaxSizeNotExceeded public function @dataProvider provideMaxSizeNotExceededTests
FileValidatorTest::testNullIsValid public function
FileValidatorTest::testUploadedFileError public function @dataProvider uploadedFileErrorProvider
FileValidatorTest::testValidFile public function
FileValidatorTest::testValidMimeType public function
FileValidatorTest::testValidUploadedfile public function
FileValidatorTest::testValidWildcardMimeType public function
FileValidatorTest::uploadedFileErrorProvider public function