annotate lib/IMPL/Test/Result.pm @ 409:f7eeafbd33da ref20150831

sync
author cin
date Sun, 13 Sep 2015 19:30:49 +0300
parents c6e90e02dd17
children 9335cf010b23
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
407
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
1 package IMPL::Test::Result;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
2 use strict;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
3 use warnings;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
4
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
5 use parent qw(IMPL::Object IMPL::Object::Autofill IMPL::Object::Serializable);
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
6 use IMPL::Class::Property;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
7
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
8 __PACKAGE__->PassThroughArgs;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
9
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
10 use constant {
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
11 SUCCESS => 0,
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
12 FAIL => 1,
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
13 ERROR => 2
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
14 };
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
15
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
16 BEGIN {
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
17 public property Name => prop_all;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
18 public property State => prop_all;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
19 public property Exception => prop_all;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
20 public property TimeExclusive => prop_all;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
21 public property TimeInclusive => prop_all;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
22 }
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
23
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
24 sub CTOR {
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
25 my ($this) = @_;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
26
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
27 $this->TimeInclusive(0) unless defined $this->TimeInclusive;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
28 $this->TimeExclusive(0) unless defined $this->TimeExclusive;
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
29 }
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
30
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
31
c6e90e02dd17 renamed Lib->lib
cin
parents:
diff changeset
32 1;