1
0
mirror of https://github.com/vichan-devel/vichan.git synced 2024-12-13 00:01:16 +01:00
vichan/inc/lib/htmlpurifier-4.5.0/tests/HTMLPurifier/AttrTransform/NameTest.php

32 lines
678 B
PHP
Raw Normal View History

2014-09-24 01:25:04 +02:00
<?php
class HTMLPurifier_AttrTransform_NameTest extends HTMLPurifier_AttrTransformHarness
{
function setUp() {
parent::setUp();
$this->obj = new HTMLPurifier_AttrTransform_Name();
}
function testEmpty() {
$this->assertResult( array() );
}
function testTransformNameToID() {
$this->assertResult(
array('name' => 'free'),
array('id' => 'free')
);
}
function testExistingIDOverridesName() {
$this->assertResult(
array('name' => 'tryit', 'id' => 'tobad'),
array('id' => 'tobad')
);
}
}
// vim: et sw=4 sts=4