blob: add67dfd9fcff825e137842b1d31e9d664729079 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
package FixMyStreet::Test;
use parent qw(Exporter);
use strict;
use warnings FATAL => 'all';
use utf8;
use Test::More;
use FixMyStreet::DB;
my $db = FixMyStreet::DB->storage;
sub import {
strict->import;
warnings->import(FATAL => 'all');
utf8->import;
Test::More->export_to_level(1);
$db->txn_begin;
}
BEGIN {
use FixMyStreet;
FixMyStreet->test_mode(1);
}
END {
$db->txn_rollback if $db;
}
1;
|