Codebase list libhttp-browserdetect-perl / a0b231d
Merge tag 'upstream/1.60' into upstream Upstream version 1.60 gregor herrmann 10 years ago
9 changed file(s) with 21 addition(s) and 21 deletion(s). Raw diff Collapse all Expand all
1919 "Olaf Alders <olaf\@wundercounter.com> (current maintainer)"
2020 ],
2121 "dist_name" => "HTTP-BrowserDetect",
22 "dist_version" => "1.59",
22 "dist_version" => "1.60",
2323 "license" => "perl",
2424 "module_name" => "HTTP::BrowserDetect",
2525 "recommends" => {},
00 Revision history for Perl extension HTTP::BrowserDetect.
1
2 1.60 2013-08-29 23:02:13 America/Toronto
3 - Fixes bug where "Linux" rather than "Android" was returned as os_string
4 for Android devices.
15
26 1.59 2013-08-18 00:38:21 America/Toronto
37 - Revert 1.57's behaviour of returning a robot name in browser_string.
6262 "web" : "https://github.com/oalders/http-browserdetect"
6363 }
6464 },
65 "version" : "1.59",
65 "version" : "1.60",
6666 "x_contributors" : [
6767 "Aran Deltac <bluefeet@gmail.com>",
6868 "Douglas Christopher Wilson <doug@somethingdoug.com>",
3535 "Test::Most" => 0,
3636 "Test::NoWarnings" => 0
3737 },
38 "VERSION" => "1.59",
38 "VERSION" => "1.60",
3939 "test" => {
4040 "TESTS" => "t/*.t"
4141 }
22 an HTTP user agent string
33
44 VERSION
5 version 1.59
5 version 1.60
66
77 SYNOPSIS
88 use HTTP::BrowserDetect;
44 license = Perl_5
55 copyright_holder = Lee Semel
66 copyright_year = 2013
7 version = 1.59
7 version = 1.60
88 main_module = lib/HTTP/BrowserDetect.pm
99
1010 [GatherDir]
22
33 package HTTP::BrowserDetect;
44 {
5 $HTTP::BrowserDetect::VERSION = '1.59';
5 $HTTP::BrowserDetect::VERSION = '1.60';
66 }
77
88 use vars qw(@ALL_TESTS);
10521052 return 'Win8' if $self->win8;
10531053 return 'WinNT' if $self->winnt;
10541054 return 'Windows Phone' if $self->winphone;
1055 return 'Mac OS X' if $self->macosx;
10561055 return 'Win3x' if $self->win3x;
1057 return 'OS2' if $self->os2;
1058 return 'Unix' if $self->unix && !$self->linux;
1056 return 'Android' if $self->android;
10591057 return 'Linux' if $self->linux;
1058 return 'Unix' if $self->unix;
10601059 return 'Firefox OS' if $self->firefoxos;
10611060 return 'RIM Tablet OS' if $self->rimtabletos;
10621061 return 'Playstation 3 GameOS' if $self->ps3gameos;
10631062 return 'Playstation Portable GameOS' if $self->pspgameos;
10641063 return 'iOS' if $self->iphone || $self->ipod || $self->ipad;
1064 return 'Mac OS X' if $self->macosx;
10651065 return 'Mac' if $self->mac;
1066 return 'OS2' if $self->os2;
10661067 return;
10671068 }
10681069
14511452
14521453 =head1 VERSION
14531454
1454 version 1.59
1455 version 1.60
14551456
14561457 =head1 SYNOPSIS
14571458
22 use strict;
33 use warnings;
44
5 use File::Slurp;
6 use FindBin;
7 use JSON::PP;
85 use Test::Most;
96 use Test::FailWarnings;
107
8 use File::Slurp;
9 use FindBin;
10 use HTTP::BrowserDetect;
11 use JSON::PP;
12
1113 bail_on_fail();
12
13 # test that the module loads without errors
14 my $w;
15 {
16 local $SIG{__WARN__} = sub { $w = shift };
17 require_ok( 'HTTP::BrowserDetect' );
18 }
19 ok !$w;
2014
2115 my $json = read_file( "$FindBin::Bin/useragents.json" );
2216
26222622 "mobile"
26232623 ],
26242624 "os" : "Android",
2625 "os_string": "Android",
26252626 "public_major" : "9",
26262627 "public_minor" : "0.80",
26272628 "public_version" : "9.80"