]> git.donarmstrong.com Git - deb_pkgs/libstatistics-r-perl.git/blob - t/04-start-stop.t
Import Upstream version 0.24
[deb_pkgs/libstatistics-r-perl.git] / t / 04-start-stop.t
1 #! perl
2
3 use strict;
4 use warnings;
5 use Test::More;
6 use Statistics::R;
7 use Cwd;
8
9 plan tests => 16;
10
11
12 my $R;
13
14 my $initial_dir = cwd;
15
16 ok $R = Statistics::R->new();
17
18 is $R->is_started, 0;
19
20 is $R->is_shared, 0;
21
22 ok $R->stop();
23
24 ok $R->stop();
25
26 ok $R->start();
27
28 is $R->is_started, 1;
29
30 is $R->is_shared, 0;
31
32 ok $R->start();
33
34 is cwd, $initial_dir; # Bug RT #6724 and #70307
35
36 ok $R->restart();
37
38 ok $R->stop();
39
40 ok $R->start( shared => 1);
41
42 is $R->is_shared, 1;
43
44 ok $R->stop();
45
46 is cwd, $initial_dir; # Bug RT #6724 and #70307