Group
Extension

Matches 2

Mojo-UserAgent-Mockable ( P/PO/POPEFELIX/Mojo-UserAgent-Mockable-1.59.tar.gz, POPEFELIX, 2022; MetaCPAN )
Mojo-UserAgent-Mockable/lib/Mojo/UserAgent/Mockable.pm ( view source; MetaCPAN )
t::Mockable;
$Mojo::UserAgent::Mockable::VERSION = '1.59';
use warnings::register;

use Carp;
use JSON::MaybeXS;
use Mojolicious 7.22;
use Mojo::Base 'Mojo::UserAgent';
use Mojo::Util qw/secure_compar
Mojo::UserAgent::Mockable::Serializer;
use Mojo::UserAgent::Mockable::Request::Compare;
use Mojo::JSON;
use Scalar::Util;

# ABSTRACT: A Mojo User-Agent that can record and play back requests without 
e  L</save> is 
called, the transaction cache will be written to the file specfied by L</file> in JSON format. 
Transactions are stored in the cache in the order they were made.

The file's contents a
Mojo-UserAgent-Mockable ( P/PO/POPEFELIX/Mojo-UserAgent-Mockable-1.59.tar.gz, POPEFELIX, 2022; MetaCPAN )
Mojo-UserAgent-Mockable/lib/Mojo/UserAgent/Mockable/Serializer.pm ( view source; MetaCPAN )
use Carp;
use Class::Load ':all';
use English qw/-no_match_vars/;
use Path::Tiny;
use JSON::MaybeXS qw/decode_json/;
use Mojo::Base 'Mojo::EventEmitter';
use Safe::Isa (qw/$_isa/);
use Try::Tiny;

# A
) {
        $serialized[$_]->{txn_num} = $_;
    }
    my $JSON = JSON::MaybeXS->new(pretty => 1, canonical => 1, utf8 => 1);
    return $JSON->encode( \@serialized );
}

sub _serialize_tx {
    my ( 
}
    return $slush;
}

sub deserialize {
    my ( $self, $frozen ) = @_;

    my $slush = decode_json($frozen);

    if ( ref $slush ne 'ARRAY' ) {
        croak q{Invalid serialized data: not stored

Powered by Groonga
Maintained by Kenichi Ishigaki <ishigaki@cpan.org>. If you find anything, submit it on GitHub.