# # Conditional build: %bcond_without tests # do not perform "make test" # %define pdir Test %define pnam WWW-Selenium Summary: Test::WWW::Selenium - Test applications using Selenium Remote Control Name: perl-Test-WWW-Selenium Version: 1.25 Release: 1 License: GPL v1+ or Artistic Group: Development/Languages/Perl Source0: http://www.cpan.org/modules/by-module/Test/%{pdir}-%{pnam}-%{version}.tar.gz # Source0-md5: e1dc1e8ee1cf83ad188f38604d1ad95b URL: http://search.cpan.org/dist/Test-WWW-Selenium/ BuildRequires: perl-devel >= 1:5.8.0 BuildRequires: rpm-perlprov >= 4.1-13 %if %{with tests} BuildRequires: perl-libwww BuildRequires: perl-URI BuildRequires: perl(Test::Exception) BuildRequires: perl(Test::Mock::LWP) %endif BuildArch: noarch BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %description This module is a WWW::Selenium subclass providing some methods useful for writing tests. For each Selenium command (open, click, type, ...) there is a corresponding _ok method that checks the return value (open_ok, click_ok, type_ok). For each Selenium getter (get_title, ...) there are four autogenerated methods (_is, _isnt, _like, _unlike) to check the value of the attribute. By calling the constructor with default_names set to a true value your tests will be given a reasonable name should you choose not to provide one of your own. The test name should always be the third argument. %prep %setup -q -n %{pdir}-%{pnam}-%{version} %build %{__perl} Makefile.PL \ INSTALLDIRS=vendor %{__make} %{?with_tests:%{__make} test} %install rm -rf $RPM_BUILD_ROOT %{__make} pure_install \ DESTDIR=$RPM_BUILD_ROOT %clean rm -rf $RPM_BUILD_ROOT %files %defattr(644,root,root,755) %doc Changes README todo.txt %{perl_vendorlib}/Test/WWW/*.pm %{perl_vendorlib}/Test/WWW/*.pl %dir %{perl_vendorlib}/WWW %{perl_vendorlib}/WWW/*.pm %dir %{perl_vendorlib}/WWW/Selenium %{perl_vendorlib}/WWW/Selenium/*.pm %{_mandir}/man3/*