diff --git a/tests/HTMLPurifier/HTMLDefinitionTest.php b/tests/HTMLPurifier/HTMLDefinitionTest.php
index 56d680f8..3e8a1da7 100644
--- a/tests/HTMLPurifier/HTMLDefinitionTest.php
+++ b/tests/HTMLPurifier/HTMLDefinitionTest.php
@@ -222,6 +222,17 @@ public function test_AllowedAttributes_multipleErrors()
$this->assertPurification_AllowedAttributes_local_p_style();
}
+ public function test_AllowedAttributes_invalidAttributeDueToConsistingOfNumbers_UsingDirectLex()
+ {
+ $this->config->set('HTML.AllowedElements', array('a'));
+ $this->config->set('HTML.AllowedAttributes', 'href');
+ $this->config->set('Core.LexerImpl', 'DirectLex');
+ $this->assertPurification(
+ 'Test',
+ 'Test'
+ );
+ }
+
public function test_ForbiddenElements()
{
$this->config->set('HTML.ForbiddenElements', 'b');