Mercurial > pub > Impl
comparison Lib/IMPL/Test/HarnessRunner.pm @ 0:03e58a454b20
Создан репозитарий
| author | Sergey |
|---|---|
| date | Tue, 14 Jul 2009 12:54:37 +0400 |
| parents | |
| children | 16ada169ca75 |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:03e58a454b20 |
|---|---|
| 1 package IMPL::Test::HarnessRunner; | |
| 2 use strict; | |
| 3 use warnings; | |
| 4 | |
| 5 use base qw(IMPL::Object IMPL::Object::Autofill IMPL::Object::Serializable); | |
| 6 use IMPL::Class::Property; | |
| 7 use Test::Harness; | |
| 8 | |
| 9 __PACKAGE__->PassThroughArgs; | |
| 10 | |
| 11 BEGIN { | |
| 12 public property Strap => prop_all; | |
| 13 } | |
| 14 | |
| 15 sub CTOR { | |
| 16 my $this = shift; | |
| 17 | |
| 18 die new IMPL::InvalidArgumentException("The Strap parameter must be specified") unless $this->Strap; | |
| 19 } | |
| 20 | |
| 21 sub RunTests { | |
| 22 my ($this,@files) = @_; | |
| 23 | |
| 24 local $Test::Harness::Strap = $this->Strap; | |
| 25 | |
| 26 return runtests(@files); | |
| 27 } | |
| 28 | |
| 29 sub ExecuteTests { | |
| 30 my ($this,%args) = @_; | |
| 31 | |
| 32 local $Test::Harness::Strap = $this->Strap; | |
| 33 | |
| 34 return Test::Harness::execute_tests(%args); | |
| 35 } | |
| 36 | |
| 37 1; |
