From 7c07bb3b246c15306d5b5853a5f1eba172d147bc Mon Sep 17 00:00:00 2001 From: adamgsoc2013 Date: Wed, 12 Jun 2013 00:08:33 +0800 Subject: [PATCH 1/2] add test for transformation class: Text_Plain_Append --- .../Text_Plain_Append_test.php | 83 +++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 test/classes/plugin/transformations/Text_Plain_Append_test.php diff --git a/test/classes/plugin/transformations/Text_Plain_Append_test.php b/test/classes/plugin/transformations/Text_Plain_Append_test.php new file mode 100644 index 0000000000..1a870f3e9a --- /dev/null +++ b/test/classes/plugin/transformations/Text_Plain_Append_test.php @@ -0,0 +1,83 @@ +assertEquals( + $info, + Text_Plain_Append_getInfo() + ); + + } + + /** + * Test for getName + * + * @return void + * + * @group medium + */ + public function testGetName() + { + $this->assertEquals( + "Append", + Text_Plain_Append::getName() + ); + } + + /** + * Test for getMIMEType + * + * @return void + * + * @group medium + */ + public function testGetMIMEType() + { + $this->assertEquals( + "Text", + Text_Plain_Append::getMIMEType() + ); + } + + /** + * Test for getMIMESubtype + * + * @return void + * + * @group medium + */ + public function testGetMIMESubtype() + { + $this->assertEquals( + "Plain", + Text_Plain_Append::getMIMESubtype() + ); + } +} From 95f29b01c7acc69b0c1b28a3b38100d69aa35d51 Mon Sep 17 00:00:00 2001 From: adamgsoc2013 Date: Wed, 12 Jun 2013 00:20:12 +0800 Subject: [PATCH 2/2] testing Text_Plain_Append::getInfo() instead of Text_Plain_Append_getInfo() --- test/classes/plugin/transformations/Text_Plain_Append_test.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/classes/plugin/transformations/Text_Plain_Append_test.php b/test/classes/plugin/transformations/Text_Plain_Append_test.php index 1a870f3e9a..6a033ecddb 100644 --- a/test/classes/plugin/transformations/Text_Plain_Append_test.php +++ b/test/classes/plugin/transformations/Text_Plain_Append_test.php @@ -31,7 +31,7 @@ class Text_Plain_Append_Test extends PHPUnit_Framework_TestCase . ' (enclosed in single quotes, default empty string).'; $this->assertEquals( $info, - Text_Plain_Append_getInfo() + Text_Plain_Append::getInfo() ); }