alt and title methods
This commit is contained in:
parent
3511ae9b42
commit
45e432c824
|
@ -29,8 +29,8 @@ class ComicPressBackendFilesystem extends ComicPressBackend {
|
|||
}
|
||||
|
||||
function file($size = null) { return $this->files_by_type[$this->ensure_type($size)]; }
|
||||
function alt() {}
|
||||
function title() {}
|
||||
function alt() { return $this->alt_text; }
|
||||
function title() { return $this->title_text; }
|
||||
}
|
||||
|
||||
class ComicPressBackendFilesystemFactory {
|
||||
|
|
|
@ -67,4 +67,14 @@ class ComicPressBackendFilesystemTest extends PHPUnit_Framework_TestCase {
|
|||
|
||||
$this->assertEquals('file', $fs->file('type'));
|
||||
}
|
||||
|
||||
function testAlt() {
|
||||
$this->fs->alt_text = 'text';
|
||||
$this->assertEquals('text', $this->fs->alt());
|
||||
}
|
||||
|
||||
function testTitle() {
|
||||
$this->fs->title_text = 'text';
|
||||
$this->assertEquals('text', $this->fs->title());
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue