%global enable_tests 1 %global srcname std-mocks Name: nodejs-%{srcname} Version: 1.0.0 Release: 1%{?dist} Summary: Mock node stdout and stderr without pain License: MIT URL: https://www.npmjs.com/package/std-mocks Source0: https://registry.npmjs.org/%{srcname}/-/%{srcname}-%{version}.tgz BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch BuildRequires: nodejs-packaging %if 0%{?enable_tests} BuildRequires: npm(chai) BuildRequires: npm(mocha) BuildRequires: npm(lodash) %endif %description %{summary}. %prep %setup -q -n package rm -rf node_modules %build #nothing to do %install mkdir -p %{buildroot}%{nodejs_sitelib}/%{srcname} chmod 644 LICENSE cp -pr package.json index.js \ %{buildroot}%{nodejs_sitelib}/%{srcname} %nodejs_symlink_deps %if 0%{?enable_tests} %check %nodejs_symlink_deps --check mocha %endif %files %doc README.md %license LICENSE %{nodejs_sitelib}/%{srcname} %changelog * Sat Oct 24 2015 Piotr Popieluch - 1.0.0-1 - Initial package