add (broken) tests for Services_Tag::normalize and Bookmark2Tag::attachTags with some empty tags
This commit is contained in:
parent
f8b5ad1cad
commit
c4ba9ef2d2
@ -89,7 +89,15 @@ class Bookmark2TagTest extends TestBase
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
public function testAttachTagsWithSomeEmptyTags()
|
||||
{
|
||||
$bid = $this->addBookmark(null, null, 0, array());
|
||||
$this->b2ts->attachTags($bid, array('foo', '', 'bar', 'baz'));
|
||||
$this->assertEquals(
|
||||
array('foo', 'bar', 'baz'),
|
||||
$this->b2ts->getTagsForBookmark($bid)
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test getTagsForBookmark() when the bookmark has no tags
|
||||
|
@ -87,5 +87,13 @@ class TagTest extends TestBase
|
||||
|
||||
}
|
||||
|
||||
public function testNormalizeEmptyValues()
|
||||
{
|
||||
$tags = $this->ts->normalize(
|
||||
array('foo', '', 'bar', 'baz')
|
||||
);
|
||||
$this->assertEquals(array('foo', 'bar', 'baz'), $tags);
|
||||
}
|
||||
|
||||
}
|
||||
?>
|
||||
|
Loading…
Reference in New Issue
Block a user