summary refs log tree commit diff
path: root/t/006_runner.t
diff options
context:
space:
mode:
authorJonathan "Duke" Leto <jonathan@leto.net>2011-02-04 17:55:13 -0800
committerJonathan "Duke" Leto <jonathan@leto.net>2011-02-04 17:55:13 -0800
commit7e3bee05bb1abcae98b2a715edc6ea49c1dae9f6 (patch)
tree459d5494a01bb5404c4940f9b16c5c50b8ee5979 /t/006_runner.t
parentUse a stringified version object, because it is prettier (diff)
downloadjitterbug-7e3bee05bb1abcae98b2a715edc6ea49c1dae9f6.tar.gz
The start of factoring out a runner from a builder runner
Diffstat (limited to 't/006_runner.t')
-rw-r--r--t/006_runner.t24
1 files changed, 24 insertions, 0 deletions
diff --git a/t/006_runner.t b/t/006_runner.t
new file mode 100644
index 0000000..b95abb2
--- /dev/null
+++ b/t/006_runner.t
@@ -0,0 +1,24 @@
+
+use strict;
+use warnings;
+use Test::Most tests => 3;
+use Data::Dumper;
+
+use jitterbug::Runner;
+
+{
+    local @ARGV = qw(-c t/data/test.yml);
+    my $b = jitterbug::Runner->new();
+
+    isa_ok($b,'jitterbug::Runner');
+    can_ok($b,qw/new run run_task sleep/);
+
+}
+
+{
+    local @ARGV = qw(-c blarg.yml);
+    throws_ok (sub {
+        my $b = jitterbug::Runner->new('blarg.yml');
+    }, qr/Does not exist/i, 'nonexistent yaml file throws error');
+}
+