debian/0000755000000000000000000000000012230267177007175 5ustar debian/rules0000755000000000000000000000003612230267177010254 0ustar #!/usr/bin/make -f %: dh $@ debian/control0000644000000000000000000000401212230267177010575 0ustar Source: libmock-quick-perl Maintainer: Debian Perl Group Uploaders: gregor herrmann , Xavier Guimard Section: perl Priority: optional Build-Depends: debhelper (>= 8), perl, perl (>= 5.17.1) | libmodule-build-perl (>= 0.400000) Build-Depends-Indep: libexporter-declare-perl, libfennec-lite-perl, libtest-exception-perl Standards-Version: 3.9.4 Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-perl/packages/libmock-quick-perl.git Vcs-Git: git://anonscm.debian.org/pkg-perl/packages/libmock-quick-perl.git Homepage: https://metacpan.org/release/Mock-Quick/ Package: libmock-quick-perl Architecture: all Depends: ${misc:Depends}, ${perl:Depends}, libexporter-declare-perl Description: Perl module for quick side-effect free mocking of objects and classes Mock::Quick is here to solve the current problems with Mocking libraries. . There are a couple Mocking libraries available on CPAN. The primary problems with these libraries include verbose syntax, and most importantly side-effects. Some Mocking libraries expect you to mock a specific class, and will unload it then redefine it. This is particularly a problem if you only want to override a class on a lexical level. . Mock::Quick provides a declarative mocking interface that results in a very concise, but clear syntax. There are separate facilities for mocking object instances, and classes. You can quickly create an instance of an object with custom attributes and methods. You can also quickly create an anonymous class, optionally inhereting from another, with whatever methods you desire. . Mock::Quick also provides a tool that provides an OO interface to overriding methods in existing classes. This tool also allows for the restoration of the original class methods. Best of all this is a localized tool, when your control object falls out of scope the original class is restored. debian/source/0000755000000000000000000000000012230267177010475 5ustar debian/source/format0000644000000000000000000000001412230267177011703 0ustar 3.0 (quilt) debian/changelog0000644000000000000000000000165712230267177011060 0ustar libmock-quick-perl (1.107-1) unstable; urgency=low * New upstream release. * Switch order of alternative build dependency. -- gregor herrmann Fri, 18 Oct 2013 19:23:08 +0200 libmock-quick-perl (1.106-1) unstable; urgency=low * Imported Upstream version 1.106 * Update spelling patch offsets * Add myself to uploaders -- Xavier Guimard Tue, 18 Jun 2013 06:26:38 +0200 libmock-quick-perl (1.105-1) unstable; urgency=low [ Salvatore Bonaccorso ] * Change Vcs-Git to canonical URI (git://anonscm.debian.org) [ gregor herrmann ] * New upstream release. * Bump build dependency on Module::Build. * Update years of packaging copyright. -- gregor herrmann Sun, 17 Feb 2013 19:40:31 +0100 libmock-quick-perl (1.104-1) unstable; urgency=low * Initial release (closes: #696082). -- gregor herrmann Sun, 16 Dec 2012 16:51:34 +0100 debian/compat0000644000000000000000000000000212230267177010373 0ustar 8 debian/patches/0000755000000000000000000000000012230267177010624 5ustar debian/patches/spelling.patch0000644000000000000000000000731312230267177013466 0ustar Description: spelling fixes Origin: vendor Bug: https://rt.cpan.org/Ticket/Display.html?id=82025 Forwarded: https://rt.cpan.org/Ticket/Display.html?id=82025 Author: gregor herrmann Reviewed-By: Xavier Guimard Last-Update: 2013-06-18 --- a/README +++ b/README @@ -9,11 +9,11 @@ problems with these libraries include verbose syntax, and most importantly side-effects. Some Mocking libraries expect you to mock a specific class, and will unload it then redefine it. This is - particularily a problem if you only want to override a class on a + particularly a problem if you only want to override a class on a lexical level. Mock-Object provides a declarative mocking interface that results in a - very concise, but clear syntax. There are seperate facilities for + very concise, but clear syntax. There are separate facilities for mocking object instances, and classes. You can quickly create an instance of an object with custom attributes and methods. You can also quickly create an anonymous class, optionally inhereting from another, @@ -233,7 +233,7 @@ is deleted. Metrics only apply to mocked methods. When you takeover an already - loaded class metrics will only track overriden methods. + loaded class metrics will only track overridden methods. EXPORTS Mock-Quick uses Exporter::Declare. This allows for exports to be --- a/lib/Mock/Quick.pm +++ b/lib/Mock/Quick.pm @@ -100,11 +100,11 @@ There are a couple Mocking libraries available on CPAN. The primary problems with these libraries include verbose syntax, and most importantly side-effects. Some Mocking libraries expect you to mock a specific class, and will unload it -then redefine it. This is particularily a problem if you only want to override +then redefine it. This is particularly a problem if you only want to override a class on a lexical level. Mock-Object provides a declarative mocking interface that results in a very -concise, but clear syntax. There are seperate facilities for mocking object +concise, but clear syntax. There are separate facilities for mocking object instances, and classes. You can quickly create an instance of an object with custom attributes and methods. You can also quickly create an anonymous class, optionally inhereting from another, with whatever methods you desire. @@ -338,7 +338,7 @@ been called. When a method is altered or removed the key is deleted. Metrics only apply to mocked methods. When you takeover an already loaded class -metrics will only track overriden methods. +metrics will only track overridden methods. =head1 EXPORTS --- a/t/Class.t +++ b/t/Class.t @@ -60,7 +60,7 @@ my $obj = $CLASS->new( foo => 'bar' ); is( $obj->package->foo, 'bar', "original value" ); $obj->override( 'foo', sub { 'baz' } ); - is( $obj->package->foo, 'baz', "overriden" ); + is( $obj->package->foo, 'baz', "overridden" ); $obj->restore('foo'); is( $obj->package->foo, 'bar', "original value" ); @@ -72,14 +72,14 @@ ); $obj->override( 'bar', sub { 'xxx' } ); - is( $obj->package->bar, 'xxx', "overriden" ); + is( $obj->package->bar, 'xxx', "overridden" ); $obj->restore('bar'); ok( !$obj->package->can('bar'), "original value is nill" ); # Multiple overrides $obj->override( foo => sub { 'foo' }, bar => sub { 'bar' } ); - is $obj->package->foo => 'foo', "overriden"; - is $obj->package->bar => 'bar', "overriden"; + is $obj->package->foo => 'foo', "overridden"; + is $obj->package->bar => 'bar', "overridden"; $obj->restore(qw/ foo bar /); is $obj->package->foo => 'bar', "original value"; ok !$obj->package->can('bar'), "original value is nil"; debian/patches/series0000644000000000000000000000001712230267177012037 0ustar spelling.patch debian/copyright0000644000000000000000000000211212230267177011124 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: Mock-Quick Source: https://metacpan.org/release/Mock-Quick/ Upstream-Contact: Chad Granum Files: * Copyright: 2011, Chad Granum License: Artistic or GPL-1+ Files: debian/* Copyright: 2012-2013, gregor herrmann 2013, Xavier Guimard License: Artistic or GPL-1+ License: Artistic This program is free software; you can redistribute it and/or modify it under the terms of the Artistic License, which comes with Perl. . On Debian systems, the complete text of the Artistic License can be found in `/usr/share/common-licenses/Artistic'. License: GPL-1+ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version. . On Debian systems, the complete text of version 1 of the GNU General Public License can be found in `/usr/share/common-licenses/GPL-1'. debian/watch0000644000000000000000000000016212230267177010225 0ustar version=3 https://metacpan.org/release/Mock-Quick/ .*/Mock-Quick-v?(\d[\d.-]*)\.(?:tar(?:\.gz|\.bz2)?|tgz|zip)$