From 961afa19301fabfa65848242e896cc1e6a267f04 Mon Sep 17 00:00:00 2001 From: thomascube Date: Wed, 4 Mar 2009 10:02:55 +0000 Subject: Add tests for external stylesheet handling --- tests/mailfunc.php | 6 +++++- tests/src/htmlbody.txt | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/mailfunc.php b/tests/mailfunc.php index 8fd2cd3d5..ae35c5d77 100644 --- a/tests/mailfunc.php +++ b/tests/mailfunc.php @@ -55,15 +55,19 @@ class rcube_test_mailfunc extends UnitTestCase $this->assertNoPattern('/
]+>/', $html, "No form tags allowed"); $this->assertPattern('/Subscription form/', $html, "Include contents"); $this->assertPattern('//', $html, "No input elements allowed"); + $this->assertPattern('//', $html, "No external links allowed"); $this->assertPattern('/]+ target="_blank">/', $html, "Set target to _blank"); $this->assertTrue($GLOBALS['REMOTE_OBJECTS'], "Remote object detected"); // render HTML in safe mode - $html2 = rcmail_print_body($part, array('safe' => true)); + $html2 = rcmail_html4inline(rcmail_print_body($part, array('safe' => true)), 'foo'); $this->assertPattern('/