Bug 20042: 00-load.t fails when Elasticsearch is not installed
[koha.git] / t / SMS.t
diff --git a/t/SMS.t b/t/SMS.t
index ab1d374..21dc75b 100755 (executable)
--- a/t/SMS.t
+++ b/t/SMS.t
@@ -1,5 +1,20 @@
 #!/usr/bin/perl
 
+# This file is part of Koha.
+#
+# Koha is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# Koha 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 Koha; if not, see <http://www.gnu.org/licenses>.
+
 use Modern::Perl;
 
 use t::lib::Mocks;
@@ -15,6 +30,8 @@ my $driver = 'my mock driver';
 t::lib::Mocks::mock_preference('SMSSendDriver', $driver);
 is( C4::SMS->driver(), $driver, 'driver returns the SMSSendDriver correctly' );
 
+t::lib::Mocks::mock_preference('SMSSendUsername', 'username');
+t::lib::Mocks::mock_preference('SMSSendPassword', 'pwd');
 
 my $send_sms = C4::SMS->send_sms();
 is( $send_sms, undef, 'send_sms without arguments returns undef' );
@@ -42,3 +59,4 @@ $send_sms = C4::SMS->send_sms({
     driver => 'Test',
 });
 is( $send_sms, 1, 'send_sms returns 1' );
+