Bug 12642: t/SMS.t should not be db dependent

SMS.t should not dependent on the DB.

Test plan:
verify that prove t/SMS.t returns green even if the DB is not there.

Signed-off-by: Robin Sheat <robin@catalyst.net.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Turned off MySQL, tests still pass.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This commit is contained in:
Jonathan Druart 2014-07-25 10:59:11 +02:00 committed by Tomas Cohen Arazi
parent 3e201530ed
commit 9c138fbfb1
1 changed files with 2 additions and 0 deletions

View File

@ -30,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' );