From ad2f096ee451bd49c5198da0043cfa75bf313ef3 Mon Sep 17 00:00:00 2001
From: Demian Katz <demian.katz@villanova.edu>
Date: Tue, 10 Sep 2013 11:48:52 -0400
Subject: [PATCH] Created base class to eliminate duplication.

---
 .../src/VuFindTest/Unit/ILSDriverTestCase.php | 59 +++++++++++++++++++
 .../src/VuFindTest/ILS/Driver/AlephTest.php   | 15 +----
 .../src/VuFindTest/ILS/Driver/AmicusTest.php  | 15 +----
 .../VuFindTest/ILS/Driver/ClaviusSQLTest.php  | 15 +----
 .../src/VuFindTest/ILS/Driver/DAIATest.php    | 15 +----
 .../VuFindTest/ILS/Driver/EvergreenTest.php   | 15 +----
 .../src/VuFindTest/ILS/Driver/HorizonTest.php | 15 +----
 .../ILS/Driver/HorizonXMLAPITest.php          | 15 +----
 .../VuFindTest/ILS/Driver/InnovativeTest.php  | 15 +----
 .../src/VuFindTest/ILS/Driver/KohaTest.php    | 15 +----
 .../VuFindTest/ILS/Driver/NewGenLibTest.php   | 15 +----
 .../src/VuFindTest/ILS/Driver/PICATest.php    | 15 +----
 .../src/VuFindTest/ILS/Driver/PolarisTest.php | 20 +------
 .../src/VuFindTest/ILS/Driver/UnicornTest.php | 15 +----
 .../src/VuFindTest/ILS/Driver/VirtuaTest.php  | 15 +----
 .../ILS/Driver/VoyagerRestfulTest.php         | 15 +----
 .../src/VuFindTest/ILS/Driver/VoyagerTest.php | 15 +----
 .../src/VuFindTest/ILS/Driver/XCNCIP2Test.php | 15 +----
 .../src/VuFindTest/ILS/Driver/XCNCIPTest.php  | 15 +----
 19 files changed, 77 insertions(+), 257 deletions(-)
 create mode 100644 module/VuFind/src/VuFindTest/Unit/ILSDriverTestCase.php

diff --git a/module/VuFind/src/VuFindTest/Unit/ILSDriverTestCase.php b/module/VuFind/src/VuFindTest/Unit/ILSDriverTestCase.php
new file mode 100644
index 00000000000..42e59fe5fc6
--- /dev/null
+++ b/module/VuFind/src/VuFindTest/Unit/ILSDriverTestCase.php
@@ -0,0 +1,59 @@
+<?php
+
+/**
+ * Abstract base class for ILS driver test cases.
+ *
+ * PHP version 5
+ *
+ * Copyright (C) Villanova University 2010.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2,
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ *
+ * @category VuFind2
+ * @package  Tests
+ * @author   David Maus <maus@hab.de>
+ * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
+ * @link     http://vufind.org/wiki/vufind2:unit_tests Wiki
+ */
+namespace VuFindTest\Unit;
+
+/**
+ * Abstract base class for ILS driver test cases.
+ *
+ * @category VuFind2
+ * @package  Tests
+ * @author   David Maus <maus@hab.de>
+ * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
+ * @link     http://vufind.org/wiki/vufind2:unit_tests Wiki
+ */
+abstract class ILSDriverTestCase extends TestCase
+{
+    /**
+     * ILS driver
+     *
+     * @var \VuFind\ILS\Driver\AbstractBase
+     */
+    protected $driver;
+
+    /**
+     * Test that driver complains about missing configuration.
+     *
+     * @return void
+     */
+    public function testMissingConfiguration()
+    {
+        $this->setExpectedException('VuFind\Exception\ILS');
+        $this->driver->init();
+    }
+}
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/AlephTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/AlephTest.php
index 5f7510e6bbc..20e55c0efe0 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/AlephTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/AlephTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Aleph;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class AlephTest extends \VuFindTest\Unit\TestCase
+class AlephTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class AlephTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Aleph();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/AmicusTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/AmicusTest.php
index 6f8dc71439c..a1149d646f4 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/AmicusTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/AmicusTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Amicus;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class AmicusTest extends \VuFindTest\Unit\TestCase
+class AmicusTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class AmicusTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Amicus();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/ClaviusSQLTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/ClaviusSQLTest.php
index dfd6636b84e..97991ffdaa4 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/ClaviusSQLTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/ClaviusSQLTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\ClaviusSQL;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class ClaviusSQLTest extends \VuFindTest\Unit\TestCase
+class ClaviusSQLTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class ClaviusSQLTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new ClaviusSQL();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/DAIATest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/DAIATest.php
index 28ef40ac4db..e4460048076 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/DAIATest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/DAIATest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\DAIA;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class DAIATest extends \VuFindTest\Unit\TestCase
+class DAIATest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class DAIATest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new DAIA();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/EvergreenTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/EvergreenTest.php
index e330742ba5e..f5d28aa0a6d 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/EvergreenTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/EvergreenTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Evergreen;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class EvergreenTest extends \VuFindTest\Unit\TestCase
+class EvergreenTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class EvergreenTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Evergreen();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/HorizonTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/HorizonTest.php
index 37d446a5899..6254d17760c 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/HorizonTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/HorizonTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Horizon;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class HorizonTest extends \VuFindTest\Unit\TestCase
+class HorizonTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class HorizonTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Horizon(new \VuFind\Date\Converter());
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/HorizonXMLAPITest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/HorizonXMLAPITest.php
index 52fe4eadaec..5b027071b08 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/HorizonXMLAPITest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/HorizonXMLAPITest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\HorizonXMLAPI;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class HorizonXMLAPITest extends \VuFindTest\Unit\TestCase
+class HorizonXMLAPITest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class HorizonXMLAPITest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new HorizonXMLAPI(new \VuFind\Date\Converter());
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/InnovativeTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/InnovativeTest.php
index b1f92629132..f3f3df5f388 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/InnovativeTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/InnovativeTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Innovative;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class InnovativeTest extends \VuFindTest\Unit\TestCase
+class InnovativeTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class InnovativeTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Innovative();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/KohaTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/KohaTest.php
index a3bd4038090..84fb1975662 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/KohaTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/KohaTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Koha;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class KohaTest extends \VuFindTest\Unit\TestCase
+class KohaTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class KohaTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Koha();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/NewGenLibTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/NewGenLibTest.php
index db3cf69b1ef..672c4595ba4 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/NewGenLibTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/NewGenLibTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\NewGenLib;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class NewGenLibTest extends \VuFindTest\Unit\TestCase
+class NewGenLibTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class NewGenLibTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new NewGenLib();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/PICATest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/PICATest.php
index 1b56cb30203..84eef101cc9 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/PICATest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/PICATest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\PICA;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class PICATest extends \VuFindTest\Unit\TestCase
+class PICATest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class PICATest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new PICA();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/PolarisTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/PolarisTest.php
index ec0f7e86ab5..fb68bc8ab35 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/PolarisTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/PolarisTest.php
@@ -37,15 +37,8 @@ use VuFind\ILS\Driver\Polaris;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class PolarisTest extends \VuFindTest\Unit\TestCase
+class PolarisTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    /**
-     * Driver object
-     *
-     * @var Polaris
-     */
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -53,15 +46,4 @@ class PolarisTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Polaris();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/UnicornTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/UnicornTest.php
index 9d15f290571..0517d0c9489 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/UnicornTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/UnicornTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Unicorn;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class UnicornTest extends \VuFindTest\Unit\TestCase
+class UnicornTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class UnicornTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Unicorn(new \VuFind\Date\Converter());
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VirtuaTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VirtuaTest.php
index e174c99d4ad..e0ed85c968c 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VirtuaTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VirtuaTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Virtua;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class VirtuaTest extends \VuFindTest\Unit\TestCase
+class VirtuaTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class VirtuaTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Virtua();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VoyagerRestfulTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VoyagerRestfulTest.php
index ba0bd611c5a..606bb76fac3 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VoyagerRestfulTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VoyagerRestfulTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\VoyagerRestful;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class VoyagerRestfulTest extends \VuFindTest\Unit\TestCase
+class VoyagerRestfulTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class VoyagerRestfulTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new VoyagerRestful(new \VuFind\Date\Converter());
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VoyagerTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VoyagerTest.php
index cfbe0a708c6..e30348e278e 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VoyagerTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/VoyagerTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\Voyager;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class VoyagerTest extends \VuFindTest\Unit\TestCase
+class VoyagerTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class VoyagerTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new Voyager(new \VuFind\Date\Converter());
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/XCNCIP2Test.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/XCNCIP2Test.php
index 003232ef594..40be5c09c2d 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/XCNCIP2Test.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/XCNCIP2Test.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\XCNCIP2;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class XCNCIP2Test extends \VuFindTest\Unit\TestCase
+class XCNCIP2Test extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class XCNCIP2Test extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new XCNCIP2();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/XCNCIPTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/XCNCIPTest.php
index 1974b6ddd46..56056cce5e2 100644
--- a/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/XCNCIPTest.php
+++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ILS/Driver/XCNCIPTest.php
@@ -37,10 +37,8 @@ use VuFind\ILS\Driver\XCNCIP;
  * @license  http://opensource.org/licenses/gpl-2.0.php GNU General Public License
  * @link     http://www.vufind.org  Main Page
  */
-class XCNCIPTest extends \VuFindTest\Unit\TestCase
+class XCNCIPTest extends \VuFindTest\Unit\ILSDriverTestCase
 {
-    protected $driver;
-
     /**
      * Constructor
      */
@@ -48,15 +46,4 @@ class XCNCIPTest extends \VuFindTest\Unit\TestCase
     {
         $this->driver = new XCNCIP();
     }
-
-    /**
-     * Test that driver complains about missing configuration.
-     *
-     * @return void
-     */
-    public function testMissingConfiguration()
-    {
-        $this->setExpectedException('VuFind\Exception\ILS');
-        $this->driver->init();
-    }
 }
\ No newline at end of file
-- 
GitLab