use warnings;
use Test::More;
-use Test::Fatal;
+use Test::Exception;
use Class::MOP;
ok(!defined($Foo::{foo}), '... the %foo slot has not been created yet');
ok(!$meta->has_package_symbol('%foo'), '... the meta agrees');
-ok ! exception {
+lives_ok {
$meta->add_package_symbol('%foo' => { one => 1 });
-}, '... the %foo symbol is created succcessfully';
+} '... the %foo symbol is created succcessfully';
ok(!defined($Foo::{foo}), '... the %foo slot has not been created in the actual Foo package');
ok($meta->has_package_symbol('%foo'), '... the meta agrees');
ok(!defined($Foo::{bar}), '... the @bar slot has not been created yet');
-ok ! exception {
+lives_ok {
$meta->add_package_symbol('@bar' => [ 1, 2, 3 ]);
-}, '... created @Foo::bar successfully';
+} '... created @Foo::bar successfully';
ok(!defined($Foo::{bar}), '... the @bar slot has still not been created');
ok(!defined($Foo::{baz}), '... the %baz slot has not been created yet');
-ok ! exception {
+lives_ok {
$meta->add_package_symbol('%baz');
-}, '... created %Foo::baz successfully';
+} '... created %Foo::baz successfully';
ok(!defined($Foo::{baz}), '... the %baz slot has still not been created');