[icinga-checkins] icinga.org: icingaweb2/bugfix/ preserve-character-after-comma-in-plugin-output-11728: Add regression test for bug #11728

git at icinga.org git at icinga.org
Thu May 19 13:45:45 CEST 2016


Module: icingaweb2
Branch: bugfix/preserve-character-after-comma-in-plugin-output-11728
Commit: 06755ba7789fc8f95d5eb89d664cee6d69072e32
URL:    https://git.icinga.org/?p=icingaweb2.git;a=commit;h=06755ba7789fc8f95d5eb89d664cee6d69072e32

Author: Alexander A. Klimov <alexander.klimov at netways.de>
Date:   Thu May 19 13:45:15 2016 +0200

Add regression test for bug #11728

refs #11728

---

 .../test/php/regression/Bug11728Test.php           |   25 ++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/modules/monitoring/test/php/regression/Bug11728Test.php b/modules/monitoring/test/php/regression/Bug11728Test.php
new file mode 100644
index 0000000..90b4cbe
--- /dev/null
+++ b/modules/monitoring/test/php/regression/Bug11728Test.php
@@ -0,0 +1,25 @@
+<?php
+/* Icinga Web 2 | (c) 2016 Icinga Development Team | GPLv2+ */
+
+namespace Tests\Icinga\Module\Monitoring\Regression;
+
+require_once __DIR__ . '/../../../application/views/helpers/PluginOutput.php';
+
+use Icinga\Test\BaseTestCase;
+use Zend_View_Helper_PluginOutput;
+
+/**
+ * Regression-Test for bug #11728
+ *
+ * Plugin output renderer must preserve the first character after a comma.
+ *
+ * @see https://dev.icinga.org/issues/11728
+ */
+class Bug11728Test extends BaseTestCase
+{
+    public function testWhetherPluginOutputPreservesCharacterAfterComma()
+    {
+        $helper = new Zend_View_Helper_PluginOutput();
+        $this->assertTrue(strpos($helper->pluginOutput('<a href="#">A,BC', true), 'BC') !== false);
+    }
+}



More information about the icinga-checkins mailing list