-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New version! Now it standalone script. DELMEAFTER test added
- Loading branch information
Showing
27 changed files
with
352 additions
and
634 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,3 +19,4 @@ tmp/ | |
Debian_CPANTS.txt | ||
META.yml | ||
inc/ | ||
*.deb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
# Collection of non-functional tests | ||
|
||
This utility measures 'quality' of perl code. | ||
Quality here means: | ||
- code must have unit tests | ||
- code must have low cyclomatic complexity | ||
- code must be divided on small pieces | ||
- Perl Best Practice used | ||
- code style | ||
- distribution organized like CPAN module | ||
- code has documentation (POD) | ||
- etc. | ||
|
||
These tests can't say: "This code is good", but they can say: "This code is not ugly, not bad". | ||
|
||
In the past it was a collection of tests in 'xt' directory, | ||
but now it is a standalone utility. | ||
|
||
## Installation | ||
|
||
``` | ||
git clone [email protected]:worldmind/perlqual.git | ||
cd perlqual | ||
sudo cpanm --installdeps . | ||
# some deps may require force install | ||
sudo make install | ||
``` | ||
|
||
If you use Debian based system, instead 'make install' you can use: | ||
``` | ||
sudo checkinstall | ||
``` | ||
For uninstall use: | ||
``` | ||
sudo make uninstall | ||
or | ||
dpkg -r perlqual | ||
``` | ||
|
||
## Using | ||
|
||
1. Run | ||
``` | ||
perlqual | ||
``` | ||
in your project dir | ||
2. Run | ||
``` | ||
perlqual <project dir> | ||
``` | ||
3. Run | ||
``` | ||
PERL5LIB=./lib perlqual | ||
``` | ||
if your libraries not installed | ||
|
||
|
||
## Configuring | ||
|
||
Perlqual has one (not required) command line argument - project directory | ||
(by default it is current dir). | ||
For configuring you must create config file named .perlqual | ||
You can place this file in the home directory or in the project | ||
directory (if some project need special settings). | ||
Example and default config can be copy-pasted from __DATA__ | ||
section of perlqual script. | ||
Some tests are disabled in default config! | ||
|
||
## TODO | ||
|
||
1. Make copy-paste check based on Code::CutNPaste | ||
2. Variables names spelling? | ||
3. my -> Readonly my ? |
Oops, something went wrong.