Blob Blame History Raw
%{?nodejs_find_provides_and_requires}

%global enable_tests 0

Name:       nodejs-tape
Version:    3.0.1
Release:    2%{?dist}
Summary:    Tap-producing test harness for Node.js and browsers
License:    MIT
Group:      System Environment/Libraries
URL:        https://github.com/substack/tape
Source0:    http://registry.npmjs.org/tape/-/tape-%{version}.tgz

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(concat-stream)
BuildRequires:  npm(defined)
BuildRequires:  npm(deep-equal) >= 0.2.1
BuildRequires:  npm(falafel)
BuildRequires:  npm(jsonify)
BuildRequires:  npm(object-inspect)
BuildRequires:  npm(resumer)
BuildRequires:  npm(tap)
BuildRequires:  npm(through)
%endif

%description
%{summary}.


%prep
%setup -q -n package
%nodejs_fixdep glob '~3.2'
%nodejs_fixdep inherits '~2.0'
%nodejs_fixdep object-inspect '~1.0'


%build
#nothing to do


%install
mkdir -p %{buildroot}%{nodejs_sitelib}/tape
cp -pr package.json index.js lib/ \
    %{buildroot}%{nodejs_sitelib}/tape

mkdir -p %{buildroot}%{nodejs_sitelib}/tape/bin
install -p -D -m0755 bin/tape %{buildroot}%{nodejs_sitelib}/tape/bin/tape
mkdir -p %{buildroot}%{_bindir}
ln -sf %{nodejs_sitelib}/tape/bin/tape %{buildroot}%{_bindir}/tape

%nodejs_symlink_deps


%if 0%{?enable_tests}
%check
%nodejs_symlink_deps --check
%tap test/*.js
%endif


%files
%doc LICENSE readme.markdown
%{nodejs_sitelib}/tape
%{_bindir}/tape


%changelog
* Sun Oct 26 2014 Jamie Nguyen <jamielinux@fedoraproject.org> - 3.0.1-2
- fix dependency versions

* Sun Oct 26 2014 Tom Hughes <tom@compton.nu> - 3.0.1-1
- update to upstream release 3.0.1

* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.4-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild

* Mon Aug 05 2013 T.C. Hollingsworth <tchollingsworth@gmail.com> - 1.0.4-1
- new upstream release 1.0.4
- conditionalize ExclusiveArch

* Wed May 29 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 1.0.2-1
- initial package