%global enable_tests 0 %global srcname isstream Name: nodejs-%{srcname} Version: 0.1.2 Release: 7%{?dist} Summary: Determine if an object is a Stream License: MIT URL: https://github.com/rvagg/isstream Source0: https://registry.npmjs.org/%{srcname}/-/%{srcname}-%{version}.tgz BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch BuildRequires: nodejs-packaging %if 0%{?enable_tests} BuildRequires: npm(tape) BuildRequires: npm(core-util-is) BuildRequires: npm(isarray) BuildRequires: npm(string_decoder) BuildRequires: npm(inherits) # Package ships with two bundled versions of readable-stream for tests. # We are only interested in testing against the version which is actually in # Fedora. BuildRequires: npm(readable-stream) %endif %description %{summary}. %prep %setup -q -n package rm -rf node_modules # symlink Fedora packaged readable-stream for testing %nodejs_fixdep --dev readable-stream %build #nothing to do %install mkdir -p %{buildroot}%{nodejs_sitelib}/%{srcname} cp -pr package.json isstream.js \ %{buildroot}%{nodejs_sitelib}/%{srcname} %nodejs_symlink_deps %if 0%{?enable_tests} %check %nodejs_symlink_deps --check # extra symlinks so we use Fedora shipped readable-stream ln -s ./node_modules/readable-stream readable-stream-1.0 ln -s ./node_modules/readable-stream readable-stream-1.1 node test.js %endif %files %doc README.md %license LICENSE.md %{nodejs_sitelib}/%{srcname} %changelog * Fri Jul 13 2018 Fedora Release Engineering - 0.1.2-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild * Thu Feb 08 2018 Fedora Release Engineering - 0.1.2-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild * Thu Jul 27 2017 Fedora Release Engineering - 0.1.2-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild * Fri Feb 10 2017 Fedora Release Engineering - 0.1.2-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild * Thu Feb 04 2016 Fedora Release Engineering - 0.1.2-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild * Fri Nov 06 2015 Piotr Popieluch - 0.1.2-2 - Add readable-stream to BR and symlinks and enable tests * Sat Oct 24 2015 Piotr Popieluch - 0.1.2-1 - Initial package