Hello community,
here is the log from the commit of package perl-Test-Warnings for
openSUSE:Factory checked in at 2013-08-06 07:04:59
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-Test-Warnings (Old)
and /work/SRC/openSUSE:Factory/.perl-Test-Warnings.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "perl-Test-Warnings"
Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-Test-Warnings/perl-Test-Warnings.changes
2013-06-07 10:07:43.000000000 +0200
+++
/work/SRC/openSUSE:Factory/.perl-Test-Warnings.new/perl-Test-Warnings.changes
2013-08-06 07:05:01.000000000 +0200
@@ -1,0 +2,16 @@
+Mon Aug 5 13:17:56 UTC 2013 - [email protected]
+
+- fix usage of Module::Build::Tiny
+
+-------------------------------------------------------------------
+Sat Jul 27 11:58:35 UTC 2013 - [email protected]
+
+- updated to 0.008
+ - compile test updated, to hopefully fix mswin32 parsing issues
+ - fix subtest tests to work on Test::More before 0.95_01
+ (RT#86802)
+ - remove use of Class::Method::Modifiers
+ - new feature: warnings { code } and warning { code }, for capturing
+ the contents of warnings for subsequent testing
+
+-------------------------------------------------------------------
Old:
----
Test-Warnings-0.004.tar.gz
New:
----
Test-Warnings-0.008.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ perl-Test-Warnings.spec ++++++
--- /var/tmp/diff_new_pack.3mb6eP/_old 2013-08-06 07:05:02.000000000 +0200
+++ /var/tmp/diff_new_pack.3mb6eP/_new 2013-08-06 07:05:02.000000000 +0200
@@ -17,7 +17,7 @@
Name: perl-Test-Warnings
-Version: 0.004
+Version: 0.008
Release: 0
%define cpan_name Test-Warnings
Summary: Test for warnings and the lack of them
@@ -29,18 +29,21 @@
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: perl
BuildRequires: perl-macros
-BuildRequires: perl(Class::Method::Modifiers)
-BuildRequires: perl(Test::CheckDeps) >= 0.002
+BuildRequires: perl(Capture::Tiny)
+BuildRequires: perl(Module::Build::Tiny) >= 0.025
+BuildRequires: perl(Test::CheckDeps) >= 0.006
+BuildRequires: perl(Test::Deep)
BuildRequires: perl(Test::More) >= 0.94
BuildRequires: perl(Test::Tester) >= 0.108
BuildRequires: perl(parent)
+#BuildRequires: perl(Pod::Coverage::TrustPod)
#BuildRequires: perl(TB2::Tester)
#BuildRequires: perl(TB2::TestState)
#BuildRequires: perl(Test::CleanNamespaces)
#BuildRequires: perl(Test::NoWarnings) >= 1.04
-#BuildRequires: perl(Test::Pod::Coverage)
+#BuildRequires: perl(Test::Pod::Coverage) >= 1.08
+#BuildRequires: perl(Test::Vars)
#BuildRequires: perl(Test::Warnings)
-Requires: perl(Class::Method::Modifiers)
Requires: perl(parent)
%{perl_requires}
@@ -67,19 +70,21 @@
enthusiastically encouraged, to perform a global search-replace of the
above with 'use Test::Warnings;' whether or not your tests have a plan.
+It can also be used as a replacement for the Test::Warn manpage, if you
+wish to test the content of expected warnings; read on to find out how.
+
%prep
%setup -q -n %{cpan_name}-%{version}
%build
-%{__perl} Makefile.PL INSTALLDIRS=vendor
-%{__make} %{?_smp_mflags}
+%{__perl} Build.PL --installdirs=vendor
+./Build build --flags=%{?_smp_mflags}
%check
-%{__make} test
+./Build test
%install
-%perl_make_install
-%perl_process_packlist
+./Build install --destdir=%{buildroot} --create_packlist=0
%perl_gen_filelist
%files -f %{name}.files
++++++ Test-Warnings-0.004.tar.gz -> Test-Warnings-0.008.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/Build.PL
new/Test-Warnings-0.008/Build.PL
--- old/Test-Warnings-0.004/Build.PL 1970-01-01 01:00:00.000000000 +0100
+++ new/Test-Warnings-0.008/Build.PL 2013-07-14 21:02:14.000000000 +0200
@@ -0,0 +1,3 @@
+use 5.006;
+use Module::Build::Tiny 0.025;
+Build_PL();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/Changes
new/Test-Warnings-0.008/Changes
--- old/Test-Warnings-0.004/Changes 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/Changes 2013-07-14 21:02:14.000000000 +0200
@@ -1,5 +1,19 @@
Revision history for Test-Warnings
+0.008 2013-07-14 12:02:01 PDT-0700 (Karen Etheridge)
+ - compile test updated, to hopefully fix mswin32 parsing issues
+
+0.007 2013-07-09 15:10:36 PDT-0700 (Karen Etheridge)
+ - fix subtest tests to work on Test::More before 0.95_01
+ (RT#86802)
+
+0.006 2013-06-20 17:53:54 PDT-0700 (Karen Etheridge)
+ - remove use of Class::Method::Modifiers
+
+0.005 2013-06-20 12:18:42 PDT-0700 (Karen Etheridge)
+ - new feature: warnings { code } and warning { code }, for capturing
+ the contents of warnings for subsequent testing
+
0.004 2013-05-21 14:58:55 PDT-0700 (Karen Etheridge)
- when allowing warnings (via allow_warnings()), messages are
emitted via note() rather than warn(), for less noisy output when
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/INSTALL
new/Test-Warnings-0.008/INSTALL
--- old/Test-Warnings-0.004/INSTALL 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/INSTALL 2013-07-14 21:02:14.000000000 +0200
@@ -25,16 +25,16 @@
As a last resort, you can manually install it. Download the tarball, untar it,
then build it:
- % perl Makefile.PL
- % make && make test
+ % perl Build.PL
+ % ./Build && ./Build test
Then install it:
- % make install
+ % ./Build install
If you are installing into a system-wide directory, you may need to run:
- % sudo make install
+ % sudo ./Build install
## Documentation
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/MANIFEST
new/Test-Warnings-0.008/MANIFEST
--- old/Test-Warnings-0.004/MANIFEST 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/MANIFEST 2013-07-14 21:02:14.000000000 +0200
@@ -1,16 +1,17 @@
+Build.PL
Changes
INSTALL
LICENSE
MANIFEST
META.json
META.yml
-Makefile.PL
README
dist.ini
examples/no_plan.t
examples/sub.t
examples/synopsis.t
examples/test_nowarnings.pl
+examples/test_warning_contents.t
examples/with_done_testing.t
examples/with_plan.t
lib/Test/Warnings.pm
@@ -25,6 +26,7 @@
t/06-skip-all.t
t/07-no_plan.t
t/08-use-if.t
+t/09-warnings-contents.t
weaver.ini
xt/author/pod-spell.t
xt/release/changes_has_content.t
@@ -39,3 +41,4 @@
xt/release/pod-no404s.t
xt/release/pod-syntax.t
xt/release/test-version.t
+xt/release/unused-vars.t
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/META.json
new/Test-Warnings-0.008/META.json
--- old/Test-Warnings-0.004/META.json 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/META.json 2013-07-14 21:02:14.000000000 +0200
@@ -4,7 +4,7 @@
"Karen Etheridge <[email protected]>"
],
"dynamic_config" : 0,
- "generated_by" : "Dist::Zilla version 4.300034, CPAN::Meta::Converter
version 2.130880",
+ "generated_by" : "Dist::Zilla version 4.300035, CPAN::Meta::Converter
version 2.131560",
"license" : [
"perl_5"
],
@@ -23,13 +23,14 @@
"prereqs" : {
"configure" : {
"requires" : {
- "ExtUtils::MakeMaker" : "6.30"
+ "Module::Build::Tiny" : "0.025"
}
},
"develop" : {
"requires" : {
- "Dist::Zilla" : "4.300034",
- "Dist::Zilla::PluginBundle::Author::ETHER" : "0.006",
+ "Dist::Zilla" : "4.300035",
+ "Dist::Zilla::Plugin::ModuleBuildTiny" : "0",
+ "Dist::Zilla::PluginBundle::Author::ETHER" : "0.011",
"Test::CPAN::Changes" : "0.19",
"Test::CPAN::Meta" : "0",
"Test::Pod" : "1.41"
@@ -37,7 +38,6 @@
},
"runtime" : {
"requires" : {
- "Class::Method::Modifiers" : "0",
"Exporter" : "0",
"Test::Builder" : "0",
"parent" : "0",
@@ -48,9 +48,11 @@
},
"test" : {
"requires" : {
+ "Capture::Tiny" : "0",
"File::Find" : "0",
"File::Temp" : "0",
- "Test::CheckDeps" : "0.002",
+ "Test::CheckDeps" : "0.006",
+ "Test::Deep" : "0",
"Test::More" : "0.94",
"Test::Tester" : "0.108",
"if" : "0"
@@ -60,7 +62,7 @@
"provides" : {
"Test::Warnings" : {
"file" : "lib/Test/Warnings.pm",
- "version" : "0.004"
+ "version" : "0.008"
}
},
"release_status" : "stable",
@@ -76,16 +78,16 @@
"web" : "https://github.com/karenetheridge/Test-Warnings"
}
},
- "version" : "0.004",
+ "version" : "0.008",
"x_Dist_Zilla" : {
"perl" : {
- "version" : "5.017011"
+ "version" : "5.019001"
},
"plugins" : [
{
"class" : "Dist::Zilla::Plugin::Git::NextVersion",
"name" : "@Author::ETHER/Git::NextVersion",
- "version" : "2.013"
+ "version" : "2.014"
},
{
"class" : "Dist::Zilla::Plugin::GithubMeta",
@@ -105,7 +107,7 @@
{
"class" : "Dist::Zilla::Plugin::MetaNoIndex",
"name" : "@Author::ETHER/MetaNoIndex",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::MetaProvides::Package",
@@ -115,57 +117,57 @@
{
"class" : "Dist::Zilla::Plugin::MetaConfig",
"name" : "@Author::ETHER/MetaConfig",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::ExecDir",
"name" : "@Author::ETHER/ExecDir",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::ShareDir",
"name" : "@Author::ETHER/ShareDir",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::Git::GatherDir",
"name" : "@Author::ETHER/Git::GatherDir",
- "version" : "2.013"
+ "version" : "2.014"
},
{
"class" : "Dist::Zilla::Plugin::MetaYAML",
"name" : "@Author::ETHER/MetaYAML",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::MetaJSON",
"name" : "@Author::ETHER/MetaJSON",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::License",
"name" : "@Author::ETHER/License",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::Readme",
"name" : "@Author::ETHER/Readme",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::Manifest",
"name" : "@Author::ETHER/Manifest",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::Test::Compile",
"name" : "@Author::ETHER/Test::Compile",
- "version" : "2.002"
+ "version" : "2.005"
},
{
"class" : "Dist::Zilla::Plugin::Test::CheckDeps",
"name" : "@Author::ETHER/Test::CheckDeps",
- "version" : "0.006"
+ "version" : "0.007"
},
{
"class" : "Dist::Zilla::Plugin::NoTabsTests",
@@ -180,7 +182,7 @@
{
"class" : "Dist::Zilla::Plugin::MetaTests",
"name" : "@Author::ETHER/MetaTests",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::Test::Version",
@@ -200,17 +202,17 @@
{
"class" : "Dist::Zilla::Plugin::Test::MinimumVersion",
"name" : "@Author::ETHER/Test::MinimumVersion",
- "version" : "2.000004"
+ "version" : "2.000005"
},
{
"class" : "Dist::Zilla::Plugin::PodSyntaxTests",
"name" : "@Author::ETHER/PodSyntaxTests",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::Test::PodSpelling",
"name" : "@Author::ETHER/Test::PodSpelling",
- "version" : "2.004003"
+ "version" : "2.006000"
},
{
"class" : "Dist::Zilla::Plugin::Test::Pod::No404s",
@@ -220,22 +222,22 @@
{
"class" : "Dist::Zilla::Plugin::PruneCruft",
"name" : "@Author::ETHER/PruneCruft",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::ManifestSkip",
"name" : "@Author::ETHER/ManifestSkip",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::Git::Describe",
"name" : "@Author::ETHER/Git::Describe",
- "version" : "0.002"
+ "version" : "0.003"
},
{
"class" : "Dist::Zilla::Plugin::PkgVersion",
"name" : "@Author::ETHER/PkgVersion",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::PodWeaver",
@@ -245,12 +247,12 @@
{
"class" : "Dist::Zilla::Plugin::NextRelease",
"name" : "@Author::ETHER/NextRelease",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::AutoPrereqs",
"name" : "@Author::ETHER/AutoPrereqs",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::MinimumPerl",
@@ -265,18 +267,18 @@
"type" : "requires"
}
},
- "name" : "@Author::ETHER/Prereqs",
- "version" : "4.300034"
+ "name" : "@Author::ETHER/installer_requirements",
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::ReadmeAnyFromPod",
"name" : "@Author::ETHER/ReadmeAnyFromPod",
- "version" : "0.120120"
+ "version" : "0.131500"
},
{
- "class" : "Dist::Zilla::Plugin::MakeMaker",
- "name" : "@Author::ETHER/MakeMaker",
- "version" : "4.300034"
+ "class" : "Dist::Zilla::Plugin::ModuleBuildTiny",
+ "name" : "@Author::ETHER/ModuleBuildTiny",
+ "version" : "0.004"
},
{
"class" : "Dist::Zilla::Plugin::InstallGuide",
@@ -296,7 +298,7 @@
{
"class" : "Dist::Zilla::Plugin::Git::Check",
"name" : "@Author::ETHER/Git::Check",
- "version" : "2.013"
+ "version" : "2.014"
},
{
"class" : "Dist::Zilla::Plugin::Git::CheckFor::MergeConflicts",
@@ -316,32 +318,27 @@
{
"class" : "Dist::Zilla::Plugin::CheckPrereqsIndexed",
"name" : "@Author::ETHER/CheckPrereqsIndexed",
- "version" : "0.008"
+ "version" : "0.009"
},
{
"class" : "Dist::Zilla::Plugin::TestRelease",
"name" : "@Author::ETHER/TestRelease",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::UploadToCPAN",
"name" : "@Author::ETHER/UploadToCPAN",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::Git::Commit",
"name" : "@Author::ETHER/Git::Commit",
- "version" : "2.013"
+ "version" : "2.014"
},
{
"class" : "Dist::Zilla::Plugin::Git::Tag",
"name" : "@Author::ETHER/Git::Tag",
- "version" : "2.013"
- },
- {
- "class" : "Dist::Zilla::Plugin::Git::Push",
- "name" : "@Author::ETHER/Git::Push",
- "version" : "2.013"
+ "version" : "2.014"
},
{
"class" : "Dist::Zilla::Plugin::GitHub::Update",
@@ -349,6 +346,11 @@
"version" : "0.34"
},
{
+ "class" : "Dist::Zilla::Plugin::Git::Push",
+ "name" : "@Author::ETHER/Git::Push",
+ "version" : "2.014"
+ },
+ {
"class" : "Dist::Zilla::Plugin::InstallRelease",
"name" : "@Author::ETHER/InstallRelease",
"version" : "0.008"
@@ -356,7 +358,12 @@
{
"class" : "Dist::Zilla::Plugin::ConfirmRelease",
"name" : "@Author::ETHER/ConfirmRelease",
- "version" : "4.300034"
+ "version" : "4.300035"
+ },
+ {
+ "class" : "Dist::Zilla::Plugin::ContributorsFromGit",
+ "name" : "ContributorsFromGit",
+ "version" : "0.006"
},
{
"class" : "Dist::Zilla::Plugin::Test::Kwalitee",
@@ -366,32 +373,32 @@
{
"class" : "Dist::Zilla::Plugin::FinderCode",
"name" : ":InstallModules",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::FinderCode",
"name" : ":IncModules",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::FinderCode",
"name" : ":TestFiles",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::FinderCode",
"name" : ":ExecFiles",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::FinderCode",
"name" : ":ShareFiles",
- "version" : "4.300034"
+ "version" : "4.300035"
},
{
"class" : "Dist::Zilla::Plugin::FinderCode",
"name" : ":MainModule",
- "version" : "4.300034"
+ "version" : "4.300035"
}
],
"zilla" : {
@@ -399,9 +406,13 @@
"config" : {
"is_trial" : "0"
},
- "version" : "4.300034"
+ "version" : "4.300035"
}
},
- "x_authority" : "cpan:ETHER"
+ "x_authority" : "cpan:ETHER",
+ "x_contributors" : [
+ "Graham Knop <[email protected]>",
+ "Leon Timmermans <[email protected]>"
+ ]
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/META.yml
new/Test-Warnings-0.008/META.yml
--- old/Test-Warnings-0.004/META.yml 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/META.yml 2013-07-14 21:02:14.000000000 +0200
@@ -3,16 +3,18 @@
author:
- 'Karen Etheridge <[email protected]>'
build_requires:
+ Capture::Tiny: 0
File::Find: 0
File::Temp: 0
- Test::CheckDeps: 0.002
+ Test::CheckDeps: 0.006
+ Test::Deep: 0
Test::More: 0.94
Test::Tester: 0.108
if: 0
configure_requires:
- ExtUtils::MakeMaker: 6.30
+ Module::Build::Tiny: 0.025
dynamic_config: 0
-generated_by: 'Dist::Zilla version 4.300034, CPAN::Meta::Converter version
2.130880'
+generated_by: 'Dist::Zilla version 4.300035, CPAN::Meta::Converter version
2.131560'
license: perl
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -26,9 +28,8 @@
provides:
Test::Warnings:
file: lib/Test/Warnings.pm
- version: 0.004
+ version: 0.008
requires:
- Class::Method::Modifiers: 0
Exporter: 0
Test::Builder: 0
parent: 0
@@ -39,15 +40,15 @@
bugtracker: https://rt.cpan.org/Public/Dist/Display.html?Name=Test-Warnings
homepage: https://github.com/karenetheridge/Test-Warnings
repository: https://github.com/karenetheridge/Test-Warnings.git
-version: 0.004
+version: 0.008
x_Dist_Zilla:
perl:
- version: 5.017011
+ version: 5.019001
plugins:
-
class: Dist::Zilla::Plugin::Git::NextVersion
name: '@Author::ETHER/Git::NextVersion'
- version: 2.013
+ version: 2.014
-
class: Dist::Zilla::Plugin::GithubMeta
name: '@Author::ETHER/GithubMeta'
@@ -63,7 +64,7 @@
-
class: Dist::Zilla::Plugin::MetaNoIndex
name: '@Author::ETHER/MetaNoIndex'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::MetaProvides::Package
name: '@Author::ETHER/MetaProvides::Package'
@@ -71,47 +72,47 @@
-
class: Dist::Zilla::Plugin::MetaConfig
name: '@Author::ETHER/MetaConfig'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::ExecDir
name: '@Author::ETHER/ExecDir'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::ShareDir
name: '@Author::ETHER/ShareDir'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::Git::GatherDir
name: '@Author::ETHER/Git::GatherDir'
- version: 2.013
+ version: 2.014
-
class: Dist::Zilla::Plugin::MetaYAML
name: '@Author::ETHER/MetaYAML'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::MetaJSON
name: '@Author::ETHER/MetaJSON'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::License
name: '@Author::ETHER/License'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::Readme
name: '@Author::ETHER/Readme'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::Manifest
name: '@Author::ETHER/Manifest'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::Test::Compile
name: '@Author::ETHER/Test::Compile'
- version: 2.002
+ version: 2.005
-
class: Dist::Zilla::Plugin::Test::CheckDeps
name: '@Author::ETHER/Test::CheckDeps'
- version: 0.006
+ version: 0.007
-
class: Dist::Zilla::Plugin::NoTabsTests
name: '@Author::ETHER/NoTabsTests'
@@ -123,7 +124,7 @@
-
class: Dist::Zilla::Plugin::MetaTests
name: '@Author::ETHER/MetaTests'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::Test::Version
name: '@Author::ETHER/Test::Version'
@@ -139,15 +140,15 @@
-
class: Dist::Zilla::Plugin::Test::MinimumVersion
name: '@Author::ETHER/Test::MinimumVersion'
- version: 2.000004
+ version: 2.000005
-
class: Dist::Zilla::Plugin::PodSyntaxTests
name: '@Author::ETHER/PodSyntaxTests'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::Test::PodSpelling
name: '@Author::ETHER/Test::PodSpelling'
- version: 2.004003
+ version: 2.006000
-
class: Dist::Zilla::Plugin::Test::Pod::No404s
name: '@Author::ETHER/Test::Pod::No404s'
@@ -155,19 +156,19 @@
-
class: Dist::Zilla::Plugin::PruneCruft
name: '@Author::ETHER/PruneCruft'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::ManifestSkip
name: '@Author::ETHER/ManifestSkip'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::Git::Describe
name: '@Author::ETHER/Git::Describe'
- version: 0.002
+ version: 0.003
-
class: Dist::Zilla::Plugin::PkgVersion
name: '@Author::ETHER/PkgVersion'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::PodWeaver
name: '@Author::ETHER/PodWeaver'
@@ -175,11 +176,11 @@
-
class: Dist::Zilla::Plugin::NextRelease
name: '@Author::ETHER/NextRelease'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::AutoPrereqs
name: '@Author::ETHER/AutoPrereqs'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::MinimumPerl
name: '@Author::ETHER/MinimumPerl'
@@ -190,16 +191,16 @@
Dist::Zilla::Plugin::Prereqs:
phase: develop
type: requires
- name: '@Author::ETHER/Prereqs'
- version: 4.300034
+ name: '@Author::ETHER/installer_requirements'
+ version: 4.300035
-
class: Dist::Zilla::Plugin::ReadmeAnyFromPod
name: '@Author::ETHER/ReadmeAnyFromPod'
- version: 0.120120
+ version: 0.131500
-
- class: Dist::Zilla::Plugin::MakeMaker
- name: '@Author::ETHER/MakeMaker'
- version: 4.300034
+ class: Dist::Zilla::Plugin::ModuleBuildTiny
+ name: '@Author::ETHER/ModuleBuildTiny'
+ version: 0.004
-
class: Dist::Zilla::Plugin::InstallGuide
name: '@Author::ETHER/InstallGuide'
@@ -215,7 +216,7 @@
-
class: Dist::Zilla::Plugin::Git::Check
name: '@Author::ETHER/Git::Check'
- version: 2.013
+ version: 2.014
-
class: Dist::Zilla::Plugin::Git::CheckFor::MergeConflicts
name: '@Author::ETHER/Git::CheckFor::MergeConflicts'
@@ -231,39 +232,43 @@
-
class: Dist::Zilla::Plugin::CheckPrereqsIndexed
name: '@Author::ETHER/CheckPrereqsIndexed'
- version: 0.008
+ version: 0.009
-
class: Dist::Zilla::Plugin::TestRelease
name: '@Author::ETHER/TestRelease'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::UploadToCPAN
name: '@Author::ETHER/UploadToCPAN'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::Git::Commit
name: '@Author::ETHER/Git::Commit'
- version: 2.013
+ version: 2.014
-
class: Dist::Zilla::Plugin::Git::Tag
name: '@Author::ETHER/Git::Tag'
- version: 2.013
- -
- class: Dist::Zilla::Plugin::Git::Push
- name: '@Author::ETHER/Git::Push'
- version: 2.013
+ version: 2.014
-
class: Dist::Zilla::Plugin::GitHub::Update
name: '@Author::ETHER/GitHub::Update'
version: 0.34
-
+ class: Dist::Zilla::Plugin::Git::Push
+ name: '@Author::ETHER/Git::Push'
+ version: 2.014
+ -
class: Dist::Zilla::Plugin::InstallRelease
name: '@Author::ETHER/InstallRelease'
version: 0.008
-
class: Dist::Zilla::Plugin::ConfirmRelease
name: '@Author::ETHER/ConfirmRelease'
- version: 4.300034
+ version: 4.300035
+ -
+ class: Dist::Zilla::Plugin::ContributorsFromGit
+ name: ContributorsFromGit
+ version: 0.006
-
class: Dist::Zilla::Plugin::Test::Kwalitee
name: Test::Kwalitee
@@ -271,30 +276,33 @@
-
class: Dist::Zilla::Plugin::FinderCode
name: ':InstallModules'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::FinderCode
name: ':IncModules'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::FinderCode
name: ':TestFiles'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::FinderCode
name: ':ExecFiles'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::FinderCode
name: ':ShareFiles'
- version: 4.300034
+ version: 4.300035
-
class: Dist::Zilla::Plugin::FinderCode
name: ':MainModule'
- version: 4.300034
+ version: 4.300035
zilla:
class: Dist::Zilla::Dist::Builder
config:
is_trial: 0
- version: 4.300034
+ version: 4.300035
x_authority: cpan:ETHER
+x_contributors:
+ - 'Graham Knop <[email protected]>'
+ - 'Leon Timmermans <[email protected]>'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/Makefile.PL
new/Test-Warnings-0.008/Makefile.PL
--- old/Test-Warnings-0.004/Makefile.PL 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/Makefile.PL 1970-01-01 01:00:00.000000000 +0100
@@ -1,77 +0,0 @@
-
-use strict;
-use warnings;
-
-use 5.006;
-
-use ExtUtils::MakeMaker 6.30;
-
-
-
-my %WriteMakefileArgs = (
- "ABSTRACT" => "Test for warnings and the lack of them",
- "AUTHOR" => "Karen Etheridge <ether\@cpan.org>",
- "BUILD_REQUIRES" => {},
- "CONFIGURE_REQUIRES" => {
- "ExtUtils::MakeMaker" => "6.30"
- },
- "DISTNAME" => "Test-Warnings",
- "EXE_FILES" => [],
- "LICENSE" => "perl",
- "NAME" => "Test::Warnings",
- "PREREQ_PM" => {
- "Class::Method::Modifiers" => 0,
- "Exporter" => 0,
- "Test::Builder" => 0,
- "parent" => 0,
- "strict" => 0,
- "warnings" => 0
- },
- "TEST_REQUIRES" => {
- "File::Find" => 0,
- "File::Temp" => 0,
- "Test::CheckDeps" => "0.002",
- "Test::More" => "0.94",
- "Test::Tester" => "0.108",
- "if" => 0
- },
- "VERSION" => "0.004",
- "test" => {
- "TESTS" => "t/*.t"
- }
-);
-
-
-unless ( eval { ExtUtils::MakeMaker->VERSION(6.63_03) } ) {
- my $tr = delete $WriteMakefileArgs{TEST_REQUIRES};
- my $br = $WriteMakefileArgs{BUILD_REQUIRES};
- for my $mod ( keys %$tr ) {
- if ( exists $br->{$mod} ) {
- $br->{$mod} = $tr->{$mod} if $tr->{$mod} > $br->{$mod};
- }
- else {
- $br->{$mod} = $tr->{$mod};
- }
- }
-}
-
-unless ( eval { ExtUtils::MakeMaker->VERSION(6.56) } ) {
- my $br = delete $WriteMakefileArgs{BUILD_REQUIRES};
- my $pp = $WriteMakefileArgs{PREREQ_PM};
- for my $mod ( keys %$br ) {
- if ( exists $pp->{$mod} ) {
- $pp->{$mod} = $br->{$mod} if $br->{$mod} > $pp->{$mod};
- }
- else {
- $pp->{$mod} = $br->{$mod};
- }
- }
-}
-
-delete $WriteMakefileArgs{CONFIGURE_REQUIRES}
- unless eval { ExtUtils::MakeMaker->VERSION(6.52) };
-
-WriteMakefile(%WriteMakefileArgs);
-
-
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/README
new/Test-Warnings-0.008/README
--- old/Test-Warnings-0.004/README 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/README 2013-07-14 21:02:14.000000000 +0200
@@ -1,7 +1,7 @@
This archive contains the distribution Test-Warnings,
-version 0.004:
+version 0.008:
Test for warnings and the lack of them
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/dist.ini
new/Test-Warnings-0.008/dist.ini
--- old/Test-Warnings-0.004/dist.ini 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/dist.ini 2013-07-14 21:02:14.000000000 +0200
@@ -5,15 +5,20 @@
license = Perl_5
[@Author::ETHER]
+:version = 0.011
Git::GatherDir.exclude_filename[] = blog_20130309.md
AutoPrereqs.skip[] = ^TB2
-; we have our own patched version of pod coverage tests,
+; we have our own patched version of these tests,
; to work around Test::Warnings adding an END check
-remove = PodCoverageTests
+-remove = Test::UnusedVars
; not usable, due to plan error (TODO: diagnose/fix)
;[Test::Kwalitee::Extra]
-;; this catches on 'use Foo::Bar::Baz' in t/06-skip-all.t
-;arg = !prereq_matches_use
+; this catches on 'use Foo::Bar::Baz' in t/06-skip-all.t
+arg = !prereq_matches_use
+
+; authordep Pod::Weaver::Section::Contributors
+[ContributorsFromGit]
[Test::Kwalitee]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/examples/synopsis.t
new/Test-Warnings-0.008/examples/synopsis.t
--- old/Test-Warnings-0.004/examples/synopsis.t 2013-05-21 23:59:00.000000000
+0200
+++ new/Test-Warnings-0.008/examples/synopsis.t 2013-07-14 21:02:14.000000000
+0200
@@ -2,9 +2,10 @@
use warnings;
use Test::More;
-use Test::Warnings;
+use Test::Warnings ':all';
pass('yay!');
+like(warning { warn "oh noes!" }, qr/^oh noes/, 'we warned');
done_testing;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/examples/test_warning_contents.t
new/Test-Warnings-0.008/examples/test_warning_contents.t
--- old/Test-Warnings-0.004/examples/test_warning_contents.t 1970-01-01
01:00:00.000000000 +0100
+++ new/Test-Warnings-0.008/examples/test_warning_contents.t 2013-07-14
21:02:14.000000000 +0200
@@ -0,0 +1,28 @@
+use strict;
+use warnings FATAL => 'all';
+
+use Test::More tests => 2;
+use Test::Warnings ':all';
+use Test::Deep;
+
+my @lines;
+my @warnings = warnings {
+ warn 'testing 1 2 3'; push @lines, __LINE__;
+ warn 'another warning'; push @lines, __LINE__;
+};
+
+my $file = __FILE__;
+cmp_deeply(
+ \@warnings,
+ [
+ "testing 1 2 3 at $file line $lines[0].\n",
+ "another warning at $file line $lines[1].\n",
+ ],
+ 'successfully captured all warnings',
+);
+
+# make these warnings visible
+allow_warnings;
+warn $_ foreach @warnings;
+allow_warnings(0);
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/lib/Test/Warnings.pm
new/Test-Warnings-0.008/lib/Test/Warnings.pm
--- old/Test-Warnings-0.004/lib/Test/Warnings.pm 2013-05-21
23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/lib/Test/Warnings.pm 2013-07-14
21:02:14.000000000 +0200
@@ -2,9 +2,9 @@
use warnings;
package Test::Warnings;
{
- $Test::Warnings::VERSION = '0.004';
+ $Test::Warnings::VERSION = '0.008';
}
-# git description: v0.003-10-g02649b7
+# git description: v0.007-5-g916978f
BEGIN {
$Test::Warnings::AUTHORITY = 'cpan:ETHER';
@@ -13,9 +13,12 @@
use parent 'Exporter';
use Test::Builder;
-use Class::Method::Modifiers ();
-our @EXPORT_OK = qw(allow_warnings allowing_warnings had_no_warnings);
+our @EXPORT_OK = qw(
+ allow_warnings allowing_warnings
+ had_no_warnings
+ warnings warning
+);
our %EXPORT_TAGS = ( all => \@EXPORT_OK );
my $warnings_allowed;
@@ -59,24 +62,45 @@
}
};
+sub warnings(&)
+{
+ my $code = shift;
+ my @warnings;
+ local $SIG{__WARN__} = sub {
+ push @warnings, shift;
+ };
+ $code->();
+ @warnings;
+}
+
+sub warning(&)
+{
+ my @warnings = &warnings(@_);
+ return @warnings == 1 ? $warnings[0] : \@warnings;
+}
+
if (Test::Builder->can('done_testing'))
{
# monkeypatch Test::Builder::done_testing:
# check for any forbidden warnings, and record that we have done so
# so we do not check again via END
- Class::Method::Modifiers::install_modifier('Test::Builder',
- before => done_testing => sub {
- # only do this at the end of all tests, not at the end of a subtest
- my $builder = _builder;
- my $in_subtest_sub = $builder->can('in_subtest');
- if (not ($in_subtest_sub ? $builder->$in_subtest_sub :
$builder->parent))
- {
- local $Test::Builder::Level = $Test::Builder::Level + 3;
- had_no_warnings('no (unexpected) warnings (via done_testing)');
- $done_testing_called = 1;
- }
- },
- );
+
+ no strict 'refs';
+ my $orig = *{'Test::Builder::done_testing'}{CODE};
+ no warnings 'redefine';
+ *{'Test::Builder::done_testing'} = sub {
+ # only do this at the end of all tests, not at the end of a subtest
+ my $builder = _builder;
+ my $in_subtest_sub = $builder->can('in_subtest');
+ if (not ($in_subtest_sub ? $builder->$in_subtest_sub :
$builder->parent))
+ {
+ local $Test::Builder::Level = $Test::Builder::Level + 3;
+ had_no_warnings('no (unexpected) warnings (via done_testing)');
+ $done_testing_called = 1;
+ }
+
+ $orig->(@_);
+ };
}
END {
@@ -115,7 +139,8 @@
=encoding utf-8
-=for :stopwords Karen Etheridge smartmatch TODO subtest subtests irc YANWT
+=for :stopwords Karen Etheridge Graham Knop Leon Timmermans smartmatch TODO
subtest
+subtests irc YANWT
=head1 NAME
@@ -123,7 +148,7 @@
=head1 VERSION
-version 0.004
+version 0.008
=head1 SYNOPSIS
@@ -131,13 +156,15 @@
use Test::Warnings;
pass('yay!');
+ like(warning { warn "oh noes!" }, qr/^oh noes/, 'we warned');
done_testing;
emits TAP:
ok 1 - yay!
- ok 2 - no (unexpected) warnings (via done_testing)
- 1..2
+ ok 2 - we warned
+ ok 3 - no (unexpected) warnings (via done_testing)
+ 1..3
=head1 DESCRIPTION
@@ -164,6 +191,9 @@
enthusiastically encouraged, to perform a global search-replace of the above
with C<use Test::Warnings;> whether or not your tests have a plan.
+It can also be used as a replacement for L<Test::Warn>, if you wish to test
+the content of expected warnings; read on to find out how.
+
=head1 FUNCTIONS
The following functions are available for import (not included by default; you
@@ -192,6 +222,27 @@
automatically at the end of all tests, but can also be called manually at any
time, as often as desired.
+=item * C<< warnings( { code } ) >>
+
+Given a code block, runs the block and returns a list of all the
+(not previously allowed via C<allow_warnings>) warnings issued within. This
+lets you test for the presence of warnings that you not only would I<allow>,
+but I<must> be issued. Testing functions are not provided; given the strings
+returned, you can test these yourself using your favourite testing functions,
+such as L<Test::More::is|Test::More> or L<Test::Deep::cmp_deeply|Test::Deep>.
+
+Warnings generated by this code block are I<NOT> propagated further. However,
+since they are returned from this function with their filename and line
+numbers intact, you can re-issue them yourself immediately after calling
+C<warnings(...)>, if desired.
+
+=item * C<< warning( { code } ) >>
+
+Same as C<< warnings( { code } ) >>, except a scalar is always returned - the
+single warning produced, if there was one, or an arrayref otherwise -- which
+can be more convenient to use than C<warnings()> if you are expecting exactly
+one warning.
+
=back
=head1 OTHER OPTIONS
@@ -228,10 +279,6 @@
=item * C<< allow_warnings(qr/.../) >> - allow some warnings and not others
-=item * C<< warning_is, warning_like etc... >> - inclusion of some
-L<Test::Warn>-like functionality for testing the content of warnings, but
-closer to a L<Test::Fatal>-like syntax
-
=item * more sophisticated handling in subtests - if we save some state on the
L<Test::Builder> object itself, we can allow warnings in a subtest and then
the state will revert when the subtest ends, as well as check for warnings at
@@ -249,15 +296,32 @@
=head1 SEE ALSO
+=over 4
+
+=item *
+
L<Test::NoWarnings>
+=item *
+
L<Test::FailWarnings>
+=item *
+
L<blogs.perl.org: YANWT (Yet Another No-Warnings
Tester)|http://blogs.perl.org/users/ether/2013/03/yanwt-yet-another-no-warnings-tester.html>
+=item *
+
L<strictures> - which makes all warnings fatal in tests, hence lessening
+
the need for special warning testing
+=back
+
+L<Test::Warn>
+
+L<Test::Fatal>
+
=head1 AUTHOR
Karen Etheridge <[email protected]>
@@ -269,4 +333,18 @@
This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.
+=head1 CONTRIBUTORS
+
+=over 4
+
+=item *
+
+Graham Knop <[email protected]>
+
+=item *
+
+Leon Timmermans <[email protected]>
+
+=back
+
=cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/t/00-check-deps.t
new/Test-Warnings-0.008/t/00-check-deps.t
--- old/Test-Warnings-0.004/t/00-check-deps.t 2013-05-21 23:59:00.000000000
+0200
+++ new/Test-Warnings-0.008/t/00-check-deps.t 2013-07-14 21:02:14.000000000
+0200
@@ -1,7 +1,7 @@
use Test::More 0.94;
-use Test::CheckDeps;
+use Test::CheckDeps 0.004;
-check_dependencies();
+check_dependencies('suggests');
if (1) {
BAIL_OUT("Missing dependencies") if !Test::More->builder->is_passing;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/t/00-compile.t
new/Test-Warnings-0.008/t/00-compile.t
--- old/Test-Warnings-0.004/t/00-compile.t 2013-05-21 23:59:00.000000000
+0200
+++ new/Test-Warnings-0.008/t/00-compile.t 2013-07-14 21:02:14.000000000
+0200
@@ -1,14 +1,15 @@
-#!perl
-
use strict;
use warnings;
+# This test was generated via Dist::Zilla::Plugin::Test::Compile 2.005
+
use Test::More 0.94;
use File::Find;
use File::Temp qw{ tempdir };
+use Capture::Tiny qw{ capture };
my @modules;
find(
@@ -51,15 +52,22 @@
do { push @scripts, _find_scripts($_) if -d $_ }
for qw{ bin script scripts };
-my $plan = scalar(@modules) + scalar(@scripts);
-$plan ? (plan tests => $plan) : (plan skip_all => "no tests to run");
-
{
# fake home for cpan-testers
# no fake requested ## local $ENV{HOME} = tempdir( CLEANUP => 1 );
- like( qx{ $^X -Ilib -e "require $_; print '$_ ok'" }, qr/^\s*$_ ok/s, "$_
loaded ok" )
- for sort @modules;
+ my @warnings;
+ for my $module (sort @modules)
+ {
+ my ($stdout, $stderr, $exit) = capture {
+ system($^X, '-Ilib', '-e', qq{require $module; print qq[$module
ok]});
+ };
+ like($stdout, qr/^\s*$module ok/s, "$module loaded ok" );
+ warn $stderr if $stderr;
+ push @warnings, $stderr if $stderr;
+ }
+
+ if ($ENV{AUTHOR_TESTING}) { is(scalar(@warnings), 0, 'no warnings found');
}
SKIP: {
eval "use Test::Script 1.05; 1;";
@@ -70,5 +78,7 @@
script_compiles( $file, "$script script compiles" );
}
}
- BAIL_OUT("Compilation failures") if !Test::More->builder->is_passing;
+ BAIL_OUT("Compilation problems") if !Test::More->builder->is_passing;
}
+
+done_testing;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/t/02-done_testing.t
new/Test-Warnings-0.008/t/02-done_testing.t
--- old/Test-Warnings-0.004/t/02-done_testing.t 2013-05-21 23:59:00.000000000
+0200
+++ new/Test-Warnings-0.008/t/02-done_testing.t 2013-07-14 21:02:14.000000000
+0200
@@ -1,7 +1,7 @@
use strict;
use warnings FATAL => 'all';
-use Test::More;
+use Test::More 0.88;
use Test::Warnings;
# testing our alteration of done_testing is a bit tricky, as (duh) once we've
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/t/03-subtest.t
new/Test-Warnings-0.008/t/03-subtest.t
--- old/Test-Warnings-0.004/t/03-subtest.t 2013-05-21 23:59:00.000000000
+0200
+++ new/Test-Warnings-0.008/t/03-subtest.t 2013-07-14 21:02:14.000000000
+0200
@@ -1,15 +1,33 @@
use strict;
use warnings FATAL => 'all';
-use Test::More;
+use Test::More 0.94;
use Test::Warnings ':all';
is(1, 1, 'passing test');
+my $had_no_warnings_called;
+
+{
+ no strict 'refs';
+ my $orig = *{'Test::Warnings::had_no_warnings'}{CODE};
+ no warnings 'redefine';
+ *{'Test::Warnings::had_no_warnings'} = sub(;$) {
+ $had_no_warnings_called++;
+ $orig->(@_);
+ };
+}
+
subtest 'here is a subtest' => sub {
pass('another passing test');
- # done_testing automatically called here - but no test is added
+ # no test is added via the done_testing here
+ done_testing;
};
+ok(!$had_no_warnings_called, 'had_no_warnings was not called via the
subtest\'s done_testing');
+
done_testing;
+# we are done testing, so we need to signal our status via exit codes.
+exit($had_no_warnings_called ? 0 : 1);
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/t/04-no-tests.t
new/Test-Warnings-0.008/t/04-no-tests.t
--- old/Test-Warnings-0.004/t/04-no-tests.t 2013-05-21 23:59:00.000000000
+0200
+++ new/Test-Warnings-0.008/t/04-no-tests.t 2013-07-14 21:02:14.000000000
+0200
@@ -1,7 +1,7 @@
use strict;
use warnings;
-use Test::More;
+use Test::More 0.88;
# if all we do is load Test::Warnings and exit, we should not add a test at END
# time. For one thing, this lets this distribution generate a compilation test
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/t/08-use-if.t
new/Test-Warnings-0.008/t/08-use-if.t
--- old/Test-Warnings-0.004/t/08-use-if.t 2013-05-21 23:59:00.000000000
+0200
+++ new/Test-Warnings-0.008/t/08-use-if.t 2013-07-14 21:02:14.000000000
+0200
@@ -1,7 +1,7 @@
use strict;
use warnings FATAL => 'all';
-use Test::More;
+use Test::More 0.88;
pass 'here is a passing test, to keep plan happy';
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/t/09-warnings-contents.t
new/Test-Warnings-0.008/t/09-warnings-contents.t
--- old/Test-Warnings-0.004/t/09-warnings-contents.t 1970-01-01
01:00:00.000000000 +0100
+++ new/Test-Warnings-0.008/t/09-warnings-contents.t 2013-07-14
21:02:14.000000000 +0200
@@ -0,0 +1,90 @@
+use strict;
+use warnings FATAL => 'all';
+
+use Test::More 0.88;
+use Test::Warnings ':all';
+use Test::Deep;
+
+{
+ my @lines;
+ my @warnings = warnings {
+ warn 'testing 1 2 3'; push @lines, __LINE__;
+ };
+
+ my $file = __FILE__;
+ cmp_deeply(
+ \@warnings,
+ [
+ "testing 1 2 3 at $file line $lines[0].\n",
+ ],
+ 'warnings() successfully captured the warning',
+ );
+
+ my $warning = warning {
+ warn 'testing 1 2 3'; push @lines, __LINE__;
+ };
+ is(
+ $warning,
+ "testing 1 2 3 at $file line $lines[1].\n",
+ 'warning() successfully the warning as a string',
+ );
+}
+
+{
+ my @lines;
+ my @warnings = warnings {
+ warn 'testing 1 2 3'; push @lines, __LINE__;
+ warn 'another warning'; push @lines, __LINE__;
+ };
+
+ my $file = __FILE__;
+ cmp_deeply(
+ \@warnings,
+ [
+ "testing 1 2 3 at $file line $lines[0].\n",
+ "another warning at $file line $lines[1].\n",
+ ],
+ 'warnings() successfully captured all warnings',
+ );
+
+ my $warning = warning {
+ warn 'testing 1 2 3'; push @lines, __LINE__;
+ warn 'another warning'; push @lines, __LINE__;
+ };
+ cmp_deeply(
+ $warning,
+ [
+ "testing 1 2 3 at $file line $lines[2].\n",
+ "another warning at $file line $lines[3].\n",
+ ],
+ 'warning() successfully captured all warnings as a scalar ref',
+ );
+}
+
+{
+ my @warnings = warnings {
+ note 'no warning here';
+ note 'nor here';
+ };
+
+ cmp_deeply(
+ \@warnings,
+ [ ],
+ 'warnings() successfully captured all warnings (none!)',
+ );
+
+ my $warning = warning {
+ note 'no warning here';
+ note 'nor here';
+ };
+
+ cmp_deeply(
+ $warning,
+ [ ],
+ 'warning() successfully captured all warnings (none!)',
+ );
+
+ is(@$warning, 0, 'warning() reports zero warnings caught');
+}
+
+done_testing;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/weaver.ini
new/Test-Warnings-0.008/weaver.ini
--- old/Test-Warnings-0.004/weaver.ini 2013-05-21 23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/weaver.ini 2013-07-14 21:02:14.000000000 +0200
@@ -6,3 +6,5 @@
[-StopWords]
[-Encoding]
+
+[Contributors]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/xt/author/pod-spell.t
new/Test-Warnings-0.008/xt/author/pod-spell.t
--- old/Test-Warnings-0.004/xt/author/pod-spell.t 2013-05-21
23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/xt/author/pod-spell.t 2013-07-14
21:02:14.000000000 +0200
@@ -2,7 +2,7 @@
use warnings;
use Test::More;
-# generated by Dist::Zilla::Plugin::Test::PodSpelling 2.004003
+# generated by Dist::Zilla::Plugin::Test::PodSpelling 2.006000
eval "use Test::Spelling 0.12; use Pod::Wordlist::hanekomu; 1" or die $@;
@@ -12,6 +12,12 @@
Karen
Etheridge
ether
+Graham
+Knop
+haarg
+Leon
+Timmermans
+fawaka
lib
Test
Warnings
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/xt/release/changes_has_content.t
new/Test-Warnings-0.008/xt/release/changes_has_content.t
--- old/Test-Warnings-0.004/xt/release/changes_has_content.t 2013-05-21
23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/xt/release/changes_has_content.t 2013-07-14
21:02:14.000000000 +0200
@@ -4,7 +4,7 @@
note 'Checking Changes';
my $changes_file = 'Changes';
-my $newver = '0.004';
+my $newver = '0.008';
my $trial_token = '-TRIAL';
SKIP: {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/xt/release/clean-namespaces.t
new/Test-Warnings-0.008/xt/release/clean-namespaces.t
--- old/Test-Warnings-0.004/xt/release/clean-namespaces.t 2013-05-21
23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/xt/release/clean-namespaces.t 2013-07-14
21:02:14.000000000 +0200
@@ -1,11 +1,13 @@
use strict;
use warnings FATAL => 'all';
-use Test::More;
+use Test::More 0.88;
use Test::CleanNamespaces;
-# we would like to just do: all_namespaces_clean()
-# ...but it also does: plan(@modules)
+ # we would like to just do:
+#all_namespaces_clean();
+ # ...but it also does: plan(@modules);
+ # which is not compatible with our adding a test via END
namespaces_clean(Test::CleanNamespaces->find_modules);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/xt/release/pod-coverage.t
new/Test-Warnings-0.008/xt/release/pod-coverage.t
--- old/Test-Warnings-0.004/xt/release/pod-coverage.t 2013-05-21
23:59:00.000000000 +0200
+++ new/Test-Warnings-0.008/xt/release/pod-coverage.t 2013-07-14
21:02:14.000000000 +0200
@@ -1,18 +1,11 @@
-#!perl
-
use strict;
-use warnings;
-use Test::More;
-
-eval "require Test::Pod::Coverage; Test::Pod::Coverage->VERSION(1.08)";
-plan skip_all => "Test::Pod::Coverage 1.08 required for testing POD coverage"
- if $@;
+use warnings FATAL => 'all';
-eval "use Pod::Coverage::TrustPod";
-plan skip_all => "Pod::Coverage::TrustPod required for testing POD coverage"
- if $@;
+use Test::More 0.94;
+use Test::Pod::Coverage 1.08;
+use Pod::Coverage::TrustPod;
-use Test::Pod::Coverage tests => 2;
+use Test::Pod::Coverage;
# copied from all_pod_coverage_ok, but omitting the plan
#all_pod_coverage_ok({ coverage_class => 'Pod::Coverage::TrustPod' });
@@ -24,3 +17,4 @@
}
};
+done_testing;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/Test-Warnings-0.004/xt/release/unused-vars.t
new/Test-Warnings-0.008/xt/release/unused-vars.t
--- old/Test-Warnings-0.004/xt/release/unused-vars.t 1970-01-01
01:00:00.000000000 +0100
+++ new/Test-Warnings-0.008/xt/release/unused-vars.t 2013-07-14
21:02:14.000000000 +0200
@@ -0,0 +1,9 @@
+use strict;
+use warnings FATAL => 'all';
+
+use Test::More 0.94;
+use Test::Vars;
+
+subtest 'all_vars_ok' => sub { all_vars_ok() };
+
+done_testing;
--
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]