Fix assertion test.
Patch by kareila.
diffs (21 lines):
diff -r f359f9ff8358 -r eff31b30c83c t/assertions.t
--- a/t/assertions.t Tue Apr 20 09:29:50 2010 +0000
+++ b/t/assertions.t Tue Apr 20 09:31:34 2010 +0000
@@ -5,8 +5,7 @@ use lib "$ENV{LJHOME}/cgi-bin";
use lib "$ENV{LJHOME}/cgi-bin";
require 'ljlib.pl';
-#plan tests => ;
-plan skip_all => 'fix this test!';
+plan tests => 13;
ok(LJ::assert_is("foo", "foo"));
ok(! eval { LJ::assert_is("foo", "bar") });
@@ -51,6 +50,6 @@ LJ::load_userids_multiple([ $u->{userid}
LJ::load_userids_multiple([ $u->{userid} => \$empty ]);
ok($empty == $u, "load multiple worked");
-my $bogus = { userid => $u->{userid} + 1 };
+my $bogus = bless { userid => $u->{userid} + 1 }, 'LJ::User';
ok(! eval { LJ::load_userids_multiple([ $u->{userid} => \$bogus ]) });
like($@, qr/AssertIs/, "failed on blowing away existing user record");
_______________________________________________
dw-changelog mailing list
[email protected]
http://lists.dwscoalition.org/mailman/listinfo/dw-changelog