Files
perl-Test-PostgreSQL/perl-Test-PostgreSQL.spec

82 lines
2.5 KiB
RPMSpec

#
# spec file for package perl-Test-PostgreSQL
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: perl-Test-PostgreSQL
Version: 1.24
Release: 0
%define cpan_name Test-PostgreSQL
Summary: PostgreSQL runner for tests
License: Artistic-2.0
Group: Development/Libraries/Perl
Url: http://search.cpan.org/dist/Test-PostgreSQL/
Source0: https://cpan.metacpan.org/authors/id/T/TJ/TJC/%{cpan_name}-%{version}.tar.gz
Source1: cpanspec.yml
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: perl(DBD::Pg)
BuildRequires: perl(DBI)
BuildRequires: perl(File::Which)
BuildRequires: perl(Function::Parameters)
BuildRequires: perl(Moo)
BuildRequires: perl(Test::SharedFork) >= 0.06
BuildRequires: perl(Tie::Hash::Method)
BuildRequires: perl(Try::Tiny)
BuildRequires: perl(Types::Standard)
Requires: perl(DBD::Pg)
Requires: perl(DBI)
Requires: perl(File::Which)
Requires: perl(Function::Parameters)
Requires: perl(Moo)
Requires: perl(Tie::Hash::Method)
Requires: perl(Try::Tiny)
Requires: perl(Types::Standard)
%{perl_requires}
%description
'Test::PostgreSQL' automatically setups a PostgreSQL instance in a
temporary directory, and destroys it when the perl script exits.
This module is a fork of Test::postgresql, which was abandoned by its
author several years ago.
%prep
%setup -q -n %{cpan_name}-%{version}
# MANUAL BEGIN
sed -i -e 's/use inc::Module::Install;/use lib q[.];\nuse inc::Module::Install;/' Makefile.PL
# MANUAL END
%build
%{__perl} Makefile.PL INSTALLDIRS=vendor
%{__make} %{?_smp_mflags}
%check
%{__make} test
%install
%perl_make_install
%perl_process_packlist
%perl_gen_filelist
%files -f %{name}.files
%defattr(-,root,root,755)
%doc Changes README.md
%changelog