# Generated by go2rpm
%bcond_without check
%bcond_with network
# https://github.com/wjdp/htmltest
%global goipath github.com/wjdp/htmltest
Version: 0.10.3
%gometa
%global common_description %{expand:
htmltest runs your HTML output through a series of checks to ensure all your
links, images, scripts references work, your alt tags are filled in, et
cetera.}
%global golicenses LICENCE
%global godocs README.md
Name: htmltest
Release: 1%{?dist}
Summary: Test generated HTML for problems
License: MIT
URL: %{gourl}
Source0: %{gosource}
BuildRequires: golang(github.com/docopt/docopt-go)
BuildRequires: golang(github.com/fatih/color) >= 1.7.0
BuildRequires: golang(github.com/imdario/mergo) >= 0.3.6
BuildRequires: golang(golang.org/x/net/html)
BuildRequires: golang(gopkg.in/seborama/govcr.v2) >= 2.2.1
BuildRequires: golang(gopkg.in/yaml.v2) >= 2.2.1
%if %{with check}
# Tests
BuildRequires: golang(github.com/daviddengcn/go-assert)
%endif
%description
%{common_description}
%gopkg
%prep
%goprep
%build
%gobuild -o %{gobuilddir}/bin/htmltest %{goipath}
%install
%gopkginstall
install -m 0755 -vd %{buildroot}%{_bindir}
install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/
%if %{with check}
%check
%if !%{with network}
# Skips TestAnchorExternalBrokenNoVCR and TestCacheIntegration
%global gotestflags %{gotestflags} -run ([^Rn]|[^o]n|[^i]on|[^t]ion|[^a]tion|[^r]ation)$
%endif
%gocheck
%endif
%files
%doc README.md
%license LICENCE
%{_bindir}/*
%gopkgfiles
%changelog
* Mon Jun 10 21:46:45 EDT 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 0.10.3-1
- Initial package