]> git.pld-linux.org Git - packages/perl-Test-NoWarnings.git/blob - perl-Test-NoWarnings.spec
- updated to 1.06
[packages/perl-Test-NoWarnings.git] / perl-Test-NoWarnings.spec
1 #
2 # Conditional build:
3 %bcond_without  tests           # do not perform "make test"
4 #
5 %define pdir    Test
6 %define pnam    NoWarnings
7 Summary:        Test::NoWarnings - Make sure you didn't emit any warnings while testing
8 Summary(pl.UTF-8):      Test::NoWarnings - sprawdzanie braku ostrzeżeń podczas testów
9 Name:           perl-Test-NoWarnings
10 Version:        1.06
11 Release:        1
12 License:        LGPL
13 Group:          Development/Languages/Perl
14 Source0:        http://www.cpan.org/modules/by-module/Test/%{pdir}-%{pnam}-%{version}.tar.gz
15 # Source0-md5:  e44d8b1820b45a71e59a0119120ca622
16 URL:            https://metacpan.org/dist/Test-NoWarnings
17 BuildRequires:  perl-devel >= 1:5.8.0
18 BuildRequires:  rpm-perlprov >= 4.1-13
19 BuildRequires:  rpmbuild(macros) >= 1.745
20 %if %{with tests}
21 BuildRequires:  perl-Test-Simple >= 0.86
22 BuildRequires:  perl-Test-Tester >= 0.107
23 %endif
24 BuildArch:      noarch
25 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27 %description
28 In general, your tests shouldn't produce warnings. This modules causes
29 any warnings to be captured and stored. It automatically adds an extra
30 test that will run when your script ends to check that there were no
31 warnings. If there were any warings, the test will give a "not ok" and
32 diagnostics of where, when and what the warning was, including a stack
33 trace of what was going on when the it occurred.
34
35 If some of your tests are supposed to produce warnings then you should
36 be capturing and checking them with Test::Warn, that way
37 Test::NoWarnings will not see them and so not complain.
38
39 %description -l pl.UTF-8
40 W ogólności testy nie powinny generować ostrzeżeń. Ten moduł powoduje,
41 że wszystkie ostrzeżenia są przechwytywane i zapisywane. Automatycznie
42 dodaje dodatkowy test uruchamiany po zakończeniu skryptu, sprawdzający
43 czy nie było ostrzeżeń. Jeśli wystąpiły jakiekolwiek ostrzeżenia, test
44 wypisze "not ok" i dane diagnostyczne, w którym miejscu, kiedy i jakie
45 było ostrzeżenie, wraz ze śladem stosu tego, co działo się w chwili
46 jego wystąpienia.
47
48 Jeśli jakieś testy mają wygenerować ostrzeżenia, należy je wyłapać i
49 sprawdzić przy użyciu Test::Warn - tak, żeby Test::NoWarnings ich nie
50 zobaczył.
51
52 %prep
53 %setup -q -n %{pdir}-%{pnam}-%{version}
54
55 %build
56 %{__perl} Makefile.PL \
57         INSTALLDIRS=vendor
58 %{__make}
59
60 %{?with_tests:%{__make} test}
61
62 %install
63 rm -rf $RPM_BUILD_ROOT
64
65 %{__make} install \
66         DESTDIR=$RPM_BUILD_ROOT
67
68 %clean
69 rm -rf $RPM_BUILD_ROOT
70
71 %files
72 %defattr(644,root,root,755)
73 %doc Changes README
74 %{perl_vendorlib}/Test/NoWarnings.pm
75 %{perl_vendorlib}/Test/NoWarnings
76 %{_mandir}/man3/Test::NoWarnings.3pm*
This page took 0.148176 seconds and 4 git commands to generate.