Archive-Har

 view release on metacpan or  search on metacpan

lib/Archive/Har/Entry/Response/Content.pm  view on Meta::CPAN

__END__

=head1 NAME

Archive::Har::Entry::Response::Content - Represents the content for a response inside the HTTP Archive

=head1 VERSION

Version '0.21'

=for stopwords HAR charset

=head1 SYNOPSIS

    use Archive::Har();

    my $http_archive_string = '"log": { "version": "1.1", .... ';
    my $har = Archive::Har->new();
    $har->string($http_archive_string);
    foreach my $entry ($har->entries()) {
        my $response = $entry->response();

lib/Archive/Har/Entry/Response/Content.pm  view on Meta::CPAN

=head2 size

returns the length of the returned content in bytes

=head2 compression

returns the number of bytes saved due to compression

=head2 mime_type

returns the mime type of the response text.  The charset attribute is included if available

=head2 text

returns the plain text response.  If this field is not HTTP decoded, then the encoding field may be used

=head2 encoding

returns the encoding (such as base64) of the text field

=head2 comment

t/chrome.t  view on Meta::CPAN

            {
              "name": "referrer-policy",
              "value": "no-referrer"
            },
            {
              "name": "status",
              "value": "302"
            },
            {
              "name": "content-type",
              "value": "text/html; charset=UTF-8"
            },
            {
              "name": "location",
              "value": "https://www.google.com.au/?gfe_rd=cr&ei=nwX0WIrDFaPM8gfYsLC4Bw"
            },
            {
              "name": "cache-control",
              "value": "private"
            },
            {

t/chrome.t  view on Meta::CPAN

            {
              "name": "server",
              "value": "gws"
            },
            {
              "name": "x-frame-options",
              "value": "SAMEORIGIN"
            },
            {
              "name": "content-type",
              "value": "text/html; charset=UTF-8"
            },
            {
              "name": "status",
              "value": "200"
            },
            {
              "name": "cache-control",
              "value": "private, max-age=0"
            },
            {

t/chrome.t  view on Meta::CPAN

            },
            {
              "name": "expires",
              "value": "-1"
            }
          ],
          "cookies": [],
          "content": {
            "size": 213057,
            "mimeType": "text/html",
            "text": "<!doctype html><html itemscope=\"\" itemtype=\"http://schema.org/WebPage\" lang=\"en-AU\"><head><meta content=\"/images/branding/googleg/1x/googleg_standard_color_128dp.png\" itemprop=\"image\"><link href=\"/images/branding/produ...
          },
          "redirectURL": "",
          "headersSize": -1,
          "bodySize": -1,
          "_transferSize": 68060
        },
        "cache": {},
        "timings": {
          "blocked": 0.254000000040833,
          "dns": -1,

t/chrome.t  view on Meta::CPAN

            {
              "name": "age",
              "value": "176894"
            },
            {
              "name": "vary",
              "value": "Accept-Encoding"
            },
            {
              "name": "content-type",
              "value": "text/javascript; charset=UTF-8"
            },
            {
              "name": "status",
              "value": "200"
            },
            {
              "name": "cache-control",
              "value": "public, max-age=31536000"
            },
            {

t/chrome.t  view on Meta::CPAN

            },
            {
              "name": "expires",
              "value": "Sat, 14 Apr 2018 22:51:30 GMT"
            }
          ],
          "cookies": [],
          "content": {
            "size": 436180,
            "mimeType": "text/javascript",
            "text": "/* _GlobalPrefix_ */\n/* _Module_:quantum */\ntry{\nvar s_,s_aaa=\"function\"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError(\"ES3 does not support getters and setters.\"...
          },
          "redirectURL": "",
          "headersSize": -1,
          "bodySize": 0,
          "_transferSize": 0
        },
        "cache": {},
        "timings": {
          "blocked": 0.133999999889056,
          "dns": -1,

t/chrome.t  view on Meta::CPAN

            {
              "name": "age",
              "value": "175952"
            },
            {
              "name": "vary",
              "value": "Accept-Encoding"
            },
            {
              "name": "content-type",
              "value": "text/javascript; charset=UTF-8"
            },
            {
              "name": "status",
              "value": "200"
            },
            {
              "name": "cache-control",
              "value": "public, max-age=31536000"
            },
            {

t/chrome.t  view on Meta::CPAN

            },
            {
              "name": "expires",
              "value": "Sat, 14 Apr 2018 23:08:00 GMT"
            }
          ],
          "cookies": [],
          "content": {
            "size": 108222,
            "mimeType": "text/javascript",
            "text": "/* _GlobalPrefix_ */\n/* _Module_:sy1p */\ntry{\nvar s_vja,s_wja,s_1i,s_xja,s_2i,s_yja={};s_D(\"sy1p\");var s_3i=function(a){s_K(this,a,0,2,null,null)};s_g(s_3i,s_J);s_3i.prototype.jh=function(){return s_L(this,1)};var s_zja={};v...
          },
          "redirectURL": "",
          "headersSize": -1,
          "bodySize": -1,
          "_transferSize": 36140
        },
        "cache": {},
        "timings": {
          "blocked": 0.595999999859487,
          "dns": -1,

t/chrome.t  view on Meta::CPAN

            {
              "name": "age",
              "value": "269870"
            },
            {
              "name": "vary",
              "value": "Accept-Encoding, Origin"
            },
            {
              "name": "content-type",
              "value": "text/javascript; charset=UTF-8"
            },
            {
              "name": "status",
              "value": "200"
            },
            {
              "name": "cache-control",
              "value": "public, max-age=31536000"
            },
            {

t/chrome.t  view on Meta::CPAN

            },
            {
              "name": "expires",
              "value": "Fri, 13 Apr 2018 21:01:54 GMT"
            }
          ],
          "cookies": [],
          "content": {
            "size": 136732,
            "mimeType": "text/javascript",
            "text": "/* _GlobalPrefix_ */\nthis.gbar_=this.gbar_||{};(function(_){var window=this;\n/* _Module_:syp */\ntry{\nvar On=function(){};_.y(On,Error);_.Pn=function(){this.b=\"pending\";this.B=[];this.w=this.C=void 0};_.ae(_.Pn);var Qn=funct...
          },
          "redirectURL": "",
          "headersSize": -1,
          "bodySize": 0,
          "_transferSize": 0
        },
        "cache": {},
        "timings": {
          "blocked": 0.233000000207539,
          "dns": -1,

t/chrome.t  view on Meta::CPAN

            {
              "name": "age",
              "value": "268963"
            },
            {
              "name": "vary",
              "value": "Accept-Encoding"
            },
            {
              "name": "content-type",
              "value": "text/javascript; charset=UTF-8"
            },
            {
              "name": "status",
              "value": "200"
            },
            {
              "name": "cache-control",
              "value": "public, max-age=31536000"
            },
            {

t/chrome.t  view on Meta::CPAN

            {
              "name": "server",
              "value": "gws"
            },
            {
              "name": "x-frame-options",
              "value": "SAMEORIGIN"
            },
            {
              "name": "content-type",
              "value": "text/html; charset=UTF-8"
            },
            {
              "name": "status",
              "value": "204"
            },
            {
              "name": "alt-svc",
              "value": "quic=\":443\"; ma=2592000; v=\"37,36,35\""
            },
            {

t/fiddler2.t  view on Meta::CPAN

#!perl -T

use Test::More tests => 6;
use Archive::Har();
use JSON();

my $har = Archive::Har->new();

my $fiddler_string = <<'_FIDDLER2_RESULTS_';
{"log":{"creator":{"comment":"http://www.fiddler2.com", "version":"4.6.0.2", "name":"Fiddler"}, "entries":[{"startedDateTime":"2015-09-05T17:11:08.5888671+10:00", "response":{"headersSize":306, "httpVersion":"HTTP/1.1", "content":{"compression":0,...
_FIDDLER2_RESULTS_
ok($har->string($fiddler_string), "Successfully read Fiddler har archive for http://search.cpan.org/recent");
ok($har->version() eq '1.2', "INPUT: Fiddler produces a version 1.2 http archive");
ok($har->creator()->name() eq 'Fiddler', "INPUT: Fiddler's creator name is 'Fiddler'");
ok($har->creator()->version() eq '4.6.0.2', "INPUT: Fiddler's creator version is '4.6.0.2'");
ok($har->creator()->comment() eq 'http://www.fiddler2.com', "INPUT: Fiddler's creator comment is 'http://www.fiddler2.com'");
my $fiddler_ref = $har->hashref();
ok(!exists $fiddler_ref->{log}->{entries}->[0]->{request}->{postData}, "Empty postData entry stripped from Fiddler output");

t/firebug_cookies_n_cache.t  view on Meta::CPAN

            {
              "name": "Content-Encoding",
              "value": "gzip"
            },
            {
              "name": "Content-Length",
              "value": "322"
            },
            {
              "name": "Content-Type",
              "value": "text/html; charset=UTF-8"
            },
            {
              "name": "Date",
              "value": "Tue, 03 Apr 2012 00:22:41 GMT"
            },
            {
              "name": "Expires",
              "value": "Tue, 03 Apr 2012 00:22:41 GMT"
            },
            {

t/firebug_cookies_n_cache.t  view on Meta::CPAN

            {
              "name": "Date",
              "value": "Tue, 03 Apr 2012 00:22:42 GMT"
            },
            {
              "name": "Set-Cookie",
              "value": "accountrecoverylocale=en; Expires=Tue, 10-Apr-2012 00:22:42 GMT; Path=/accounts/recovery; Secure; HttpOnly\nmainpageaccountrecoveryparamscookie=CmJBSHdHa1JuSXI5TUhydFN0MTg1T05SMWxvLXBDcmtZejZ5TTZPc1E3YlZ6bU1uczNsMTNCV2lSOVBMV2...
            },
            {
              "name": "Content-Type",
              "value": "text/html; charset=UTF-8"
            },
            {
              "name": "Content-Encoding",
              "value": "gzip"
            },
            {
              "name": "X-Content-Type-Options",
              "value": "nosniff"
            },
            {

t/firebug_cookies_n_cache.t  view on Meta::CPAN

            {
              "name": "Date",
              "value": "Wed, 28 Mar 2012 14:27:20 GMT"
            },
            {
              "name": "Last-Modified",
              "value": "Sat, 24 Mar 2012 08:58:08 GMT"
            },
            {
              "name": "Content-Type",
              "value": "text/javascript; charset=utf-8"
            },
            {
              "name": "Content-Encoding",
              "value": "gzip"
            },
            {
              "name": "X-Content-Type-Options",
              "value": "nosniff"
            },
            {

t/firebug_cookies_n_cache.t  view on Meta::CPAN

            {
              "name": "Date",
              "value": "Mon, 02 Apr 2012 07:47:55 GMT"
            },
            {
              "name": "Last-Modified",
              "value": "Wed, 28 Mar 2012 12:40:40 GMT"
            },
            {
              "name": "Content-Type",
              "value": "text/css; charset=utf-8"
            },
            {
              "name": "Content-Encoding",
              "value": "gzip"
            },
            {
              "name": "X-Content-Type-Options",
              "value": "nosniff"
            },
            {

t/firebug_get.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 01:32:11 GMT"
            },
            {
              "name": "Content-Type",
              "value": "text/html; charset=UTF-8"
            },
            {
              "name": "Transfer-Encoding",
              "value": "chunked"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/firebug_get.t  view on Meta::CPAN

              "value": "max-age=1"
            },
            {
              "name": "Content-Encoding",
              "value": "gzip"
            }
          ],
          "content": {
            "mimeType": "text/html",
            "size": 6771,
            "text": "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\" \"http://www.w3.org/TR/html4/strict.dtd\"><html><head><meta name=\"robots\" content=\"noindex,nofollow\"><meta http-equiv=\"content-type\" content=\"text/html; charset=UTF-8\"><...
          },
          "redirectURL": "",
          "headersSize": 253,
          "bodySize": 2665
        },
        "cache": {},
        "timings": {
          "blocked": 0,
          "dns": 31,
          "connect": 796,

t/firebug_get.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 01:32:11 GMT"
            },
            {
              "name": "Content-Type",
              "value": "application/x-javascript; charset=UTF-8"
            },
            {
              "name": "Last-Modified",
              "value": "Mon, 19 Mar 2012 14:58:36 GMT"
            },
            {
              "name": "Transfer-Encoding",
              "value": "chunked"
            },
            {

t/firebug_get.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 01:32:14 GMT"
            },
            {
              "name": "Content-Type",
              "value": "application/x-javascript; charset=UTF-8"
            },
            {
              "name": "Content-Length",
              "value": "0"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/firebug_get.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 01:32:14 GMT"
            },
            {
              "name": "Content-Type",
              "value": "application/x-javascript; charset=UTF-8"
            },
            {
              "name": "Transfer-Encoding",
              "value": "chunked"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/firebug_get.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 01:32:14 GMT"
            },
            {
              "name": "Content-Type",
              "value": "application/x-javascript; charset=UTF-8"
            },
            {
              "name": "Content-Length",
              "value": "0"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/firebug_get.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 01:32:15 GMT"
            },
            {
              "name": "Content-Type",
              "value": "application/x-javascript; charset=UTF-8"
            },
            {
              "name": "Transfer-Encoding",
              "value": "chunked"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/firebug_post.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 05:27:52 GMT"
            },
            {
              "name": "Content-Type",
              "value": "text/html; charset=UTF-8"
            },
            {
              "name": "Transfer-Encoding",
              "value": "chunked"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/firebug_post.t  view on Meta::CPAN

              "value": "max-age=1"
            },
            {
              "name": "Content-Encoding",
              "value": "gzip"
            }
          ],
          "content": {
            "mimeType": "text/html",
            "size": 6730,
            "text": "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\" \"http://www.w3.org/TR/html4/strict.dtd\"><html><head><meta name=\"robots\" content=\"noindex,nofollow\"><meta http-equiv=\"content-type\" content=\"text/html; charset=UTF-8\"><...
          },
          "redirectURL": "",
          "headersSize": 253,
          "bodySize": 2673
        },
        "cache": {
          "afterRequest": {
            "expires": "1970-01-01T00:00:00.000Z",
            "lastAccess": "2012-03-23T05:31:06.000Z",
            "eTag": "",

t/firebug_post.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 05:27:53 GMT"
            },
            {
              "name": "Content-Type",
              "value": "application/x-javascript; charset=UTF-8"
            },
            {
              "name": "Transfer-Encoding",
              "value": "chunked"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/firebug_post.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 05:27:54 GMT"
            },
            {
              "name": "Content-Type",
              "value": "application/x-javascript; charset=UTF-8"
            },
            {
              "name": "Transfer-Encoding",
              "value": "chunked"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/firebug_post.t  view on Meta::CPAN

            {
              "name": "Server",
              "value": "nginx"
            },
            {
              "name": "Date",
              "value": "Fri, 23 Mar 2012 05:27:55 GMT"
            },
            {
              "name": "Content-Type",
              "value": "application/x-javascript; charset=UTF-8"
            },
            {
              "name": "Transfer-Encoding",
              "value": "chunked"
            },
            {
              "name": "Connection",
              "value": "keep-alive"
            },
            {

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                        {
                            "name" : "Content-Encoding",
                            "value" : "gzip"
                        },
                        {
                            "name" : "Content-Length",
                            "value" : "234"
                        },
                        {
                            "name" : "Content-Type",
                            "value" : "text/html; charset=UTF-8"
                        },
                        {
                            "name" : "Date",
                            "value" : "Tue, 03 Apr 2012 22:13:46 GMT"
                        },
                        {
                            "name" : "Expires",
                            "value" : "Tue, 03 Apr 2012 22:13:46 GMT"
                        },
                        {

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                            "value" : "nosniff"
                        },
                        {
                            "name" : "X-XSS-Protection",
                            "value" : "1; mode=block"
                        }
                    ],
                    "content" : {
                        "size" : 307,
                        "compression" : 73,
                        "mimeType" : "text/html; charset=UTF-8",
                        "text" : "<HTML>\n<HEAD>\n<TITLE>Moved Temporarily</TITLE>\n</HEAD>\n<BODY BGCOLOR=\"#FFFFFF\" TEXT=\"#000000\">\n<H1>Moved Temporarily</H1>\nThe document has moved <A HREF=\"https://www.google.com/accounts/recovery?hl=en&amp;...
                    },
                    "redirectURL" : "https://www.google.com/accounts/recovery?hl=en&gaps&service=mail&continue=https%3A%2F%2Fmail.google.com%2Fmail%2F",
                    "headersSize" : 627,
                    "bodySize" : 234
                },
                "cache" : {
                    "beforeRequest" : null,
                    "afterRequest" : {
                        "lastAccess" : "2012-04-03T22:13:50.000Z",

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                        {
                            "name" : "Content-Encoding",
                            "value" : "gzip"
                        },
                        {
                            "name" : "Content-Length",
                            "value" : "2533"
                        },
                        {
                            "name" : "Content-Type",
                            "value" : "text/html; charset=UTF-8"
                        },
                        {
                            "name" : "Date",
                            "value" : "Tue, 03 Apr 2012 22:13:47 GMT"
                        },
                        {
                            "name" : "Expires",
                            "value" : "Fri, 01 Jan 1990 00:00:00 GMT"
                        },
                        {

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                            "value" : "SAMEORIGIN"
                        },
                        {
                            "name" : "X-XSS-Protection",
                            "value" : "1; mode=block"
                        }
                    ],
                    "content" : {
                        "size" : 6691,
                        "compression" : 4158,
                        "mimeType" : "text/html; charset=UTF-8",
                        "text" : "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\" \"http://www.w3.org/TR/html4/strict.dtd\"><html><script type=\"text/javascript\" src=\"/accounts/recovery/resources/3135485014-options_bin.js\"></script>\n<script t...
                    },
                    "redirectURL" : "",
                    "headersSize" : 759,
                    "bodySize" : 2533
                },
                "cache" : {
                    "beforeRequest" : null,
                    "afterRequest" : {
                        "lastAccess" : "2012-04-03T22:13:51.000Z",
                        "eTag" : "",

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                        {
                            "name" : "Content-Encoding",
                            "value" : "gzip"
                        },
                        {
                            "name" : "Content-Length",
                            "value" : "15612"
                        },
                        {
                            "name" : "Content-Type",
                            "value" : "text/javascript; charset=utf-8"
                        },
                        {
                            "name" : "Date",
                            "value" : "Wed, 28 Mar 2012 14:25:49 GMT"
                        },
                        {
                            "name" : "Expires",
                            "value" : "Fri, 27 Apr 2012 14:25:49 GMT"
                        },
                        {

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                            "value" : "SAMEORIGIN"
                        },
                        {
                            "name" : "X-XSS-Protection",
                            "value" : "1; mode=block"
                        }
                    ],
                    "content" : {
                        "size" : 39903,
                        "compression" : 24291,
                        "mimeType" : "text/javascript; charset=utf-8",
                        "text" : "(function (){ function e(a){throw a;}var l=void 0,m=!0,n=null,p=!1,aa=window,r=Error,ba=parseInt,s=parseFloat,da=Function,ea=document,fa=Array,t=Math;function ga(a,b){return a.width=b}function ha(a,b){return a.innerH...
                    },
                    "redirectURL" : "",
                    "headersSize" : 396,
                    "bodySize" : 15612
                },
                "cache" : {
                    "beforeRequest" : null,
                    "afterRequest" : {
                        "expires" : "2012-04-27T14:25:49.000Z",

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                        {
                            "name" : "Content-Encoding",
                            "value" : "gzip"
                        },
                        {
                            "name" : "Content-Length",
                            "value" : "5128"
                        },
                        {
                            "name" : "Content-Type",
                            "value" : "text/css; charset=utf-8"
                        },
                        {
                            "name" : "Date",
                            "value" : "Mon, 02 Apr 2012 07:50:40 GMT"
                        },
                        {
                            "name" : "Expires",
                            "value" : "Wed, 02 May 2012 07:50:40 GMT"
                        },
                        {

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                            "value" : "SAMEORIGIN"
                        },
                        {
                            "name" : "X-XSS-Protection",
                            "value" : "1; mode=block"
                        }
                    ],
                    "content" : {
                        "size" : 33756,
                        "compression" : 28628,
                        "mimeType" : "text/css; charset=utf-8",
                        "text" : "/* Copyright 2012 Google Inc. All Rights Reserved. */\n.goog-inline-block{position:relative;display:-moz-inline-box;display:inline-block}* html .goog-inline-block{display:inline}*:first-child+html .goog-inline-block{...
                    },
                    "redirectURL" : "",
                    "headersSize" : 388,
                    "bodySize" : 5128
                },
                "cache" : {
                    "beforeRequest" : null,
                    "afterRequest" : {
                        "expires" : "2012-05-02T07:50:40.000Z",

t/httpwatch_cookies_n_cache.t  view on Meta::CPAN

                        },
                        {
                            "name" : "X-Content-Type-Options",
                            "value" : "nosniff"
                        }
                    ],
                    "content" : {
                        "size" : 34293,
                        "compression" : 20529,
                        "mimeType" : "text/javascript",
                        "text" : "(function(){var g=void 0,h=!0,i=null,j=!1,ba=encodeURIComponent,ca=Infinity,da=setTimeout,ea=decodeURIComponent,l=Math;function fa(a,b){return a.onload=b}function ga(a,b){return a.name=b}var m=\"push\",ha=\"slice\",n...
                    },
                    "redirectURL" : "",
                    "headersSize" : 373,
                    "bodySize" : 13764
                },
                "cache" : {
                    "beforeRequest" : null,
                    "afterRequest" : {
                        "expires" : "2012-04-04T00:01:28.000Z",
                        "lastAccess" : "2012-04-03T22:13:53.000Z",

t/ie_network_inspector.t  view on Meta::CPAN

                <statusText>OK</statusText>
                <httpVersion>HTTP/1.0</httpVersion>
                <cookies/>
                <headers>
                    <header>
                        <name>Connection</name>
                        <value>close</value>
                    </header>
                    <header>
                        <name>Content-Type</name>
                        <value>text/html; charset=ISO-8859-1</value>
                    </header>
                    <header>
                        <name>Date</name>
                        <value>Sun, 27 Oct 2013 14:47:53 GMT</value>
                    </header>
                    <header>
                        <name>Expires</name>
                        <value>0</value>
                    </header>
                    <header>

t/ie_network_inspector.t  view on Meta::CPAN

                        <name>Cache-Control</name>
                        <value>no-cache</value>
                    </header>
                    <header>
                        <name>Content-Length</name>
                        <value>46208</value>
                    </header>
                </headers>
                <content>
                    <size>46208</size>
                    <mimeType>text/html; charset=ISO-8859-1</mimeType>
                    <text>&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt;
&lt;html lang="en"&gt;
&lt;head&gt;
    &lt;title&gt;POPFile Control Center&lt;/title&gt;
    &lt;link rel="icon" href="favicon.ico"&gt;
    &lt;link rel="stylesheet" type="text/css" href="skins/simplyblue/style.css" title="POPFile"&gt;
    &lt;meta http-equiv="Content-Script-Type" content="text/javascript"&gt;
&lt;script type="text/javascript"&gt;
&lt;!--
function OnLoadHandler(){ return 0; }

t/ie_network_inspector.t  view on Meta::CPAN

					<header>
						<name>Cache-Control</name>
						<value>private, no-cache, no-store, must-revalidate</value>
					</header>
					<header>
						<name>Transfer-Encoding</name>
						<value>chunked</value>
					</header>
					<header>
						<name>Content-Type</name>
						<value>text/javascript; charset=UTF-8</value>
					</header>
					<header>
						<name>Location</name>
						<value>https://apis.live.net/v5.0/file.10ffe37c6737f99f.10FFE37C6737F99F!132/</value>
					</header>
					<header>
						<name>Server</name>
						<value>Live-API/16.2.1383.402 Microsoft-HTTPAPI/2.0</value>
					</header>
					<header>

t/pingdom.t  view on Meta::CPAN

#!perl -T

use Test::More tests => 64;
use Archive::Har();
use JSON();

my $har = Archive::Har->new();

my $pingdom_string = '{"log":{"version":"1.2","creator":{"name":"Pingdom Tools","version":"","comment":"Test the load time of a web page at http://tools.pingdom.com/fpt"},"pages":[{"startedDateTime":"2012-03-23T01:22:05.820Z","id":"https://duckduckgo...

ok($har->string($pingdom_string), "Successfully read pingdom har archive for https://duckduckgo.com/?q=http+archive+specification");
ok($har->version() eq '1.2', "INPUT: Pingdom produces a version 1.2 http archive");
ok($har->creator()->name() eq 'Pingdom Tools', "INPUT: Pingdom's creator name is 'Pingdom Tools'");
ok($har->creator()->version() eq '', "INPUT: Pingdom's creator version is the empty string");
ok($har->creator()->comment() eq 'Test the load time of a web page at http://tools.pingdom.com/fpt', "INPUT: Pingdom's creator comment is advertising for Pingdom");
ok(scalar $har->pages() == 1, "INPUT: Pingdom's archive contains 1 page");
my ($firstPage) = $har->pages();
ok($firstPage->started_date_time() eq '2012-03-23T01:22:05.820Z', "INPUT: Pingdom's archive page has a startedDateTime of '2012-03-23T01:22:05.820Z'");
ok($firstPage->id() eq 'https://duckduckgo.com/?q=http+archive+specification', "INPUT: Pingdom's archive page has an id of 'https://duckduckgo.com/?q=http+archive+specification'");



( run in 0.286 second using v1.01-cache-2.11-cpan-4d50c553e7e )