File: pod_spelling_common.t

package info (click to toggle)
libffi-checklib-perl 0.31-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 504 kB
  • sloc: perl: 520; sh: 20; makefile: 2
file content (29 lines) | stat: -rw-r--r-- 744 bytes parent folder | download | duplicates (23)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
use strict;
use warnings;
use Test::More;
BEGIN {
  plan skip_all => 'test requires Test::Pod::Spelling::CommonMistakes'
    unless eval q{ use Test::Pod::Spelling::CommonMistakes; 1 };
  plan skip_all => 'test requires YAML'
    unless eval q{ use YAML qw( LoadFile ); 1 };
};
use Test::Pod::Spelling::CommonMistakes;
use FindBin;
use File::Spec;

my $config_filename = File::Spec->catfile(
  $FindBin::Bin, File::Spec->updir, File::Spec->updir, 'author.yml'
);

my $config;
$config = LoadFile($config_filename)
  if -r $config_filename;

plan skip_all => 'disabled' if $config->{pod_spelling_common}->{skip};

chdir(File::Spec->catdir($FindBin::Bin, File::Spec->updir, File::Spec->updir));

# TODO: test files in bin too.
all_pod_files_ok;