re-usable test suite and Store::File added
[catagits/Web-Session.git] / t / 001_basic.t
CommitLineData
06190e8b 1#!/usr/bin/perl
2
3use strict;
4use warnings;
5
6use Test::More;
06190e8b 7
8use Plack::Request;
06190e8b 9use Plack::Session;
10use Plack::Session::State;
11use Plack::Session::Store;
12
f331b3e0 13use t::lib::TestSession;
14
15t::lib::TestSession::run_all_tests(
16 store => Plack::Session::Store->new,
17 state => Plack::Session::State->new,
18 request_creator => sub {
19 open my $in, '<', \do { my $d };
20 my $env = {
21 'psgi.version' => [ 1, 0 ],
22 'psgi.input' => $in,
23 'psgi.errors' => *STDERR,
24 'psgi.url_scheme' => 'http',
25 SERVER_PORT => 80,
26 REQUEST_METHOD => 'GET',
27 };
28 my $r = Plack::Request->new( $env );
29 $r->parameters( @_ );
30 $r;
31 },
32);
06190e8b 33
fe1bfe7d 34done_testing;