From 37e9bd4fb89d17b28a13d568e3fbf1a56d1ee6d6 Mon Sep 17 00:00:00 2001
From: Aleksander Machniak <alec@alec.pl>
Date: Thu, 22 Oct 2015 02:45:26 -0400
Subject: [PATCH] Fix testing attachments plugins after recent change that prevents from using more than one

---
 plugins/database_attachments/database_attachments.php   |    2 +-
 plugins/redundant_attachments/redundant_attachments.php |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/plugins/database_attachments/database_attachments.php b/plugins/database_attachments/database_attachments.php
index 82c2b59..f3804f3 100644
--- a/plugins/database_attachments/database_attachments.php
+++ b/plugins/database_attachments/database_attachments.php
@@ -28,7 +28,7 @@
  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
 
-if (class_exists('filesystem_attachments', false)) {
+if (class_exists('filesystem_attachments', false) && !defined('TESTS_DIR')) {
     die("Configuration issue. There can be only one enabled plugin for attachments handling");
 }
 
diff --git a/plugins/redundant_attachments/redundant_attachments.php b/plugins/redundant_attachments/redundant_attachments.php
index 2c12466..55ec3be 100644
--- a/plugins/redundant_attachments/redundant_attachments.php
+++ b/plugins/redundant_attachments/redundant_attachments.php
@@ -32,7 +32,7 @@
  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
 
-if (class_exists('filesystem_attachments', false)) {
+if (class_exists('filesystem_attachments', false) && !defined('TESTS_DIR')) {
     die("Configuration issue. There can be only one enabled plugin for attachments handling");
 }
 

--
Gitblit v1.9.1