#disabled as ava module upstream is not available %global enable_tests 0 %global module_name resolve-from Name: nodejs-%{module_name} Version: 2.0.0 Release: 1%{?dist} Summary: Resolve the path of a module like require.resolve() but from a given path License: MIT URL: https://github.com/sindresorhus/resolve-from Source0: http://registry.npmjs.org/%{module_name}/-/%{module_name}-%{version}.tgz Source1: https://raw.githubusercontent.com/sindresorhus/resolve-from/v%{version}/test.js BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch BuildRequires: nodejs-packaging %if 0%{?enable_tests} BuildRequires: npm(ava) %endif %description %{summary}. %prep %setup -q -n package rm -rf node_modules cp -p %{SOURCE1} . %build # nothing to build %install mkdir -p %{buildroot}%{nodejs_sitelib}/%{module_name} cp -pr package.json *.js %{buildroot}%{nodejs_sitelib}/%{module_name} %nodejs_symlink_deps %check %nodejs_symlink_deps --check %{__nodejs} -e 'require("./")' %if 0%{?enable_tests} node test.js %else %{_bindir}/echo -e "\e[101m -=#=- Tests disabled -=#=- \e[0m" %endif %files %{!?_licensedir:%global license %doc} %doc readme.md %license license %{nodejs_sitelib}/%{module_name} %changelog * Mon Feb 15 2016 Jared Smith - 2.0.0-1 - Update to upstream 2.0.0 release * Thu Feb 04 2016 Fedora Release Engineering - 1.0.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild * Wed Jun 17 2015 Fedora Release Engineering - 1.0.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild * Mon Dec 08 2014 Parag Nemade - 1.0.0-1 - Initial packaging