Release 2.0.1, merged in 1181 to HEAD.
[htmlpurifier.git] / tests / HTMLPurifier / AttrTransform / BorderTest.php
blob25fb3c669c39250728cb5041f429dc1ef813f904
1 <?php
3 require_once 'HTMLPurifier/AttrTransform/Border.php';
4 require_once 'HTMLPurifier/AttrTransformHarness.php';
7 class HTMLPurifier_AttrTransform_BorderTest extends HTMLPurifier_AttrTransformHarness
10 function setUp() {
11 parent::setUp();
12 $this->obj = new HTMLPurifier_AttrTransform_Border();
15 function test() {
17 $this->assertResult( array() );
19 $this->assertResult(
20 array('border' => '1'),
21 array('style' => 'border:1px solid;')
24 // once again, no validation done here, we expect CSS validator
25 // to catch it
26 $this->assertResult(
27 array('border' => '10%'),
28 array('style' => 'border:10%px solid;')
31 $this->assertResult(
32 array('border' => '23', 'style' => 'font-weight:bold;'),
33 array('style' => 'border:23px solid;font-weight:bold;')