Skip to content

Commit

Permalink
#99 fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
yegor256 committed May 2, 2024
1 parent 922eda7 commit f4fbdc7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions bibcop.pl
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,9 @@ sub check_capitalization {
if (not $word =~ /^[A-Za-z]/) {
next;
}
if ($word =~ /^\{.*|.*\}$/) {
next;
}
if (exists $minors{$word}) {
if ($pos eq 1) {
return "The minor word '$word' in the '$tag' must be upper-cased since it is the first one"
Expand Down
2 changes: 2 additions & 0 deletions perl-tests/checks.pl
Original file line number Diff line number Diff line change
Expand Up @@ -101,13 +101,15 @@ package bibcop;
check_fails($f, ('title' => 'Cilk: an Efficient Multithreaded Runtime System'));
check_fails($f, ('title' => 'in the Database'));
check_fails($f, ('title' => 'GitHub Audience?---a Thematic Analysis'));
check_fails($f, ('title' => 'Analysis of GitHub.com Users'));
check_passes($f, ('title' => 'The TeX Book'));
check_passes($f, ('title' => 'Data Flow Languages and Architecture'));
check_passes($f, ('title' => 'A Preliminary Architecture for a Basic Data-Flow Processor'));
check_passes($f, ('title' => 'Cilk: An Efficient Multithreaded Runtime System'));
check_passes($f, ('title' => 'Can Programming Be Liberated From the {von} Neumann Style? A Functional Style and Its Algebra of Programs'));
check_passes($f, ('title' => 'An Empirical Study of in C Code From GitHub'));
check_passes($f, ('title' => 'GitHub Audience?---A Thematic Analysis'));
check_passes($f, ('title' => 'Analysis of {GitHub.com} Users'));

$f = 'check_year';
check_fails($f, ('year' => 'hello'));
Expand Down

0 comments on commit f4fbdc7

Please sign in to comment.