Refactor the setup code in t/lib/common.pl
authorNicholas Clark <nick@ccl4.org>
Sun, 14 Jul 2013 15:29:59 +0000 (17:29 +0200)
committerNicholas Clark <nick@ccl4.org>
Mon, 22 Jul 2013 08:04:48 +0000 (10:04 +0200)
commit375f99fd797c34dd5b50e63b857aac456a8b276d
tree4aacac7c3a3439e529e358346e3be99de72cf824
parentf9b950a22dcff51aab6668aa7e5d67e5d8566495
Refactor the setup code in t/lib/common.pl

Eliminate the variable $line which has never been used.
(The code was added by commit bd4dea8e97f4a8f5 in June 2001.)
Use a non-capturing group in a regex.
Check the return value of close and die if there is an error.
Explicitly count the tests found.
Avoid indirect object syntax for a method call.
t/lib/common.pl