]> Sergey Matveev's repositories - public-inbox.git/blobdiff - t/html_index.t
feed: various object-orientation cleanups
[public-inbox.git] / t / html_index.t
index 6896eb41b7ff5ae8f3bc48fb9472c32e22ca584a..32d7b8de4383c01226f43c18c6695f5f522ebd2a 100644 (file)
@@ -7,10 +7,18 @@ use Email::MIME;
 use PublicInbox::Feed;
 use PublicInbox::Git;
 use PublicInbox::Import;
+use PublicInbox::Inbox;
 use File::Temp qw/tempdir/;
 my $tmpdir = tempdir('pi-http-XXXXXX', TMPDIR => 1, CLEANUP => 1);
 my $git_dir = "$tmpdir/gittest";
-my $git = PublicInbox::Git->new($git_dir);
+my $ibx = PublicInbox::Inbox->new({
+       address => 'test@example',
+       -primary_address => 'test@example',
+       name => 'tester',
+       mainrepo => $git_dir,
+       url => 'http://example.com/test',
+});
+my $git = $ibx->git;
 my $im = PublicInbox::Import->new($git, 'tester', 'test@example');
 
 # setup
@@ -55,7 +63,7 @@ EOF
 {
        use IO::File;
        my $cb = PublicInbox::Feed::generate_html_index({
-               git_dir => $git_dir,
+               -inbox => $ibx,
                max => 3
        });
        require 't/common.perl';