Bugzilla – Attachment 16900 Details for
Bug 8383
Need test to check that Perl files will compile
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 8383: Add test to check that Perl scripts
Bug-8383-Add-test-to-check-that-Perl-scripts.patch (text/plain), 2.18 KB, created by
Mason James
on 2013-03-26 18:22:11 UTC
(
hide
)
Description:
Bug 8383: Add test to check that Perl scripts
Filename:
MIME Type:
Creator:
Mason James
Created:
2013-03-26 18:22:11 UTC
Size:
2.18 KB
patch
obsolete
>From 557e6c7019d9e1b7d817e4b4f80b6185dad434b7 Mon Sep 17 00:00:00 2001 >From: Mason James <mtj@kohaaloha.com> >Date: Wed, 27 Mar 2013 07:19:09 +1300 >Subject: [PATCH] Bug 8383: Add test to check that Perl scripts >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit >Content-Type: text/plain; charset="utf-8" > >This patch adds t/db_dependent/00-strict.pl which tests that all Perl >scripts compile. I chose to use Test::Strict so that in the future we >can also have the test check that "use strict" and "use warnings" are >enabled. > >To test: >1. Run t/db_dependent/00-strict.pl. >2. Run around waving your arms in the air that we have a couple of > scripts that don't compile. >3. Actually, that's about it. You could test my patch for bug 8384 next. > >Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com> >Moved test to t/db_dependent > >Signed-off-by: Frédéric Demians <f.demians@tamil.fr> >--- > t/db_dependent/00-strict.pl | 24 ++++++++++++++++++++++++ > 1 files changed, 24 insertions(+), 0 deletions(-) > create mode 100644 t/db_dependent/00-strict.pl > >diff --git a/t/db_dependent/00-strict.pl b/t/db_dependent/00-strict.pl >new file mode 100644 >index 0000000..7869591 >--- /dev/null >+++ b/t/db_dependent/00-strict.pl >@@ -0,0 +1,24 @@ >+# This script is called by the pre-commit git hook to test modules compile >+ >+use strict; >+use warnings; >+use Test::More; >+use Test::Strict; >+use File::Spec; >+use File::Find; >+use lib("misc/translator"); >+use lib("installer"); >+ >+my @dirs = ( 'acqui', 'admin', 'authorities', 'basket', >+ 'catalogue', 'cataloguing', 'changelanguage.pl', 'circ', 'debian', 'docs', >+ 'edithelp.pl', 'errors', 'fix-perl-path.PL', 'help.pl', 'installer', >+ 'koha_perl_deps.pl', 'kohaversion.pl', 'labels', >+ 'mainpage.pl', 'Makefile.PL', 'members', 'misc', 'offline_circ', 'opac', >+ 'patroncards', 'reports', 'reserve', 'resetversion.pl', 'reviews', >+ 'rewrite-config.PL', 'rotating_collections', 'serials', 'services', 'skel', >+ 'sms', 'suggestion', 'svc', 'tags', 'tools', 'virtualshelves' ); >+ >+$Test::Strict::TEST_STRICT = 0; >+$Test::Strict::TEST_SKIP = [ 'misc/kohalib.pl', 'sms/sms_listen_windows_start.pl' ]; >+ >+all_perl_files_ok(@dirs); >-- >1.7.2.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 8383
:
10704
|
10711
|
10723
| 16900