%{?nodejs_find_provides_and_requires}
%global enable_tests 1
Name: nodejs-negotiator
Version: 0.4.3
Release: 2%{?dist}
Summary: An HTTP content negotiator for Node.js
License: MIT
Group: System Environment/Libraries
URL: https://github.com/federomero/negotiator
Source0: http://registry.npmjs.org/negotiator/-/negotiator-%{version}.tgz
# Source1 is generated by running Source10, which pulls from the upstream
# version control repository.
Source1: tests-%{version}.tar.bz2
Source2: examples-%{version}.tar.bz2
Source10: dl-tests.sh
BuildArch: noarch
%if 0%{?fedora} >= 19
ExclusiveArch: %{nodejs_arches} noarch
%else
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
%endif
BuildRequires: nodejs-packaging
%if 0%{?enable_tests}
BuildRequires: npm(nodeunit)
%endif
%description
%{summary}.
%prep
%setup -q -n package
%setup -q -T -D -a 1 -n package
%setup -q -T -D -a 2 -n package
%build
#nothing to do
%install
mkdir -p %{buildroot}%{nodejs_sitelib}/negotiator
cp -pr package.json lib/ \
%{buildroot}%{nodejs_sitelib}/negotiator
%nodejs_symlink_deps
%if 0%{?enable_tests}
%check
%nodejs_symlink_deps --check
/usr/bin/nodeunit test
%endif
%files
%doc LICENSE readme.md examples/
%{nodejs_sitelib}/negotiator
%changelog
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
* Sun Apr 20 2014 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.4.3-1
- update to upstream release 0.4.3
* Sun Mar 02 2014 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.4.2-1
- initial package