Mercurial > pub > Impl
diff _test/Test/DOM/Schema.pm @ 19:1ca530e5c9c5
DOM схема, требует переработки в части схемы для описания схем. Автоверификация не проходит
author | Sergey |
---|---|
date | Fri, 11 Sep 2009 16:30:39 +0400 |
parents | |
children | 7f00786f8210 |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/_test/Test/DOM/Schema.pm Fri Sep 11 16:30:39 2009 +0400 @@ -0,0 +1,24 @@ +package Test::DOM::Schema; +use strict; +use warnings; + +use base qw(IMPL::Test::Unit); +use IMPL::Test qw(test failed); + +__PACKAGE__->PassThroughArgs; + +require IMPL::DOM::Schema; + +test GetMetaSchema => sub { + my $metaSchema = IMPL::DOM::Schema->MetaSchema(); +}; + +test AutoverifyMetaSchema => sub { + my $metaSchema = IMPL::DOM::Schema->MetaSchema(); + + if (my @errors = $metaSchema->Validate($metaSchema)) { + failed "Self verification failed", map $_ ? $_->Message : 'unknown', @errors; + } +}; + +1;