Permalink
Browse files

Merged

  • Loading branch information...
1 parent bc502e5 commit 6be1ae68d191f38ce0667d324c719f2cfe5d1656 @limitusus committed Apr 20, 2012
Showing with 5 additions and 1 deletion.
  1. +3 −1 e3/lib/Tweet.pm
  2. +2 −0 e3/t/forest.t
View
@@ -4,13 +4,15 @@ use strict;
use warnings;
use DateTime;
+use Time::HiRes;
sub new {
my $class = shift;
my %info = @_;
+ my $stamp = Time::HiRes::time();
my $self = {
owner => $info{owner},
- stamp => DateTime->now,
+ stamp => DateTime->from_epoch(epoch => $stamp),
message => $info{message},
};
return bless $self, $class;
View
@@ -69,6 +69,8 @@ sub tweet :Tests {
$b1->tweet("Hello!");
$b2->tweet("Hi!");
$b1->tweet("hoge");
+ use Data::Dumper;
+ warn Dumper(\{$b2->friends_timeline});
is $b1->tweets->[0]->message, "Hello!";
is $b1->tweets->[1]->message, "hoge";
is $b2->tweets->[0]->message, "Hi!";

0 comments on commit 6be1ae6

Please sign in to comment.