eZ\Publish\Core\FieldType\Tests\ImageTest::provideValidInputForAcceptValue PHP Method

provideValidInputForAcceptValue() public method

Returns an array of data provider sets with 2 arguments: 1. The valid input to acceptValue(), 2. The expected return value from acceptValue(). For example: return array( array( null, null ), array( __FILE__, new BinaryFileValue( array( 'id' => __FILE__, 'fileName' => basename( __FILE__ ), 'fileSize' => filesize( __FILE__ ), 'downloadCount' => 0, 'mimeType' => 'text/plain', ) ) ), ... );
    public function provideValidInputForAcceptValue()
    {
        return array(array(null, new ImageValue()), array(array(), new ImageValue()), array(new ImageValue(), new ImageValue()), array($this->getImageInputPath(), new ImageValue(array('inputUri' => $this->getImageInputPath(), 'fileName' => basename($this->getImageInputPath()), 'fileSize' => filesize($this->getImageInputPath()), 'alternativeText' => null))), array(array('id' => $this->getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', 'uri' => 'http://' . $this->getImageInputPath()), new ImageValue(array('id' => $this->getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', 'uri' => 'http://' . $this->getImageInputPath()))), array(array('inputUri' => $this->getImageInputPath(), 'fileName' => 'My Fancy Filename', 'fileSize' => 123), new ImageValue(array('inputUri' => $this->getImageInputPath(), 'fileName' => 'My Fancy Filename', 'fileSize' => filesize($this->getImageInputPath())))));
    }