diff --git a/.gitignore b/.gitignore index e69de29..f1702bd 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/lolex-1.3.1.tgz diff --git a/nodejs-lolex.spec b/nodejs-lolex.spec new file mode 100644 index 0000000..33c53ca --- /dev/null +++ b/nodejs-lolex.spec @@ -0,0 +1,74 @@ +# Test deps: npm(referee) and npm(sinon) not yet in Fedora +%global enable_tests 0 +%global srcname lolex + +Name: nodejs-%{srcname} +Version: 1.3.1 +Release: 2%{?dist} +Summary: Fake JavaScript timers +License: BSD +URL: https://github.com/sinonjs/lolex +Source0: https://registry.npmjs.org/%{srcname}/-/%{srcname}-%{version}.tgz + +BuildArch: noarch +ExclusiveArch: %{nodejs_arches} noarch + +BuildRequires: nodejs-packaging + +%if 0%{?enable_tests} +BuildRequires: npm(referee) +BuildRequires: npm(sinon) +%endif + + +%description +JavaScript implementation of the timer APIs; setTimeout, clearTimeout, +setImmediate, clearImmediate, setInterval, clearInterval, and +requestAnimationFrame, along with a clock instance that controls the flow of +time. Lolex also provides a Date implementation that gets its time from the +clock. + + +%prep +%setup -q -n package + + +%build +#nothing to do + + +%install +mkdir -p %{buildroot}%{nodejs_sitelib}/%{srcname} +cp -pr package.json src/ \ + %{buildroot}%{nodejs_sitelib}/%{srcname} + +%nodejs_symlink_deps + + +%if 0%{?enable_tests} +%check +%nodejs_symlink_deps --check +npm run test-node +%endif + + +%files +%doc Readme.md +%license LICENSE +%{nodejs_sitelib}/%{srcname} + + +%changelog +* Tue Sep 01 2015 Piotr Popieluch - 1.3.1-2 +- remove toplevel lolex.js +- remove tests from rpm +- update test for only testing Node.js part + +* Sat Aug 29 2015 Piotr Popieluch - 1.3.1-1 +- update to latest upstream + +* Fri Jan 02 2015 Piotr Popieluch - 1.2.0-1 +- update to latest upstream + +* Tue Nov 18 2014 Piotr Popieluch - 1.1.0-1 +- Initial package diff --git a/sources b/sources index e69de29..109886f 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +e508dd0fd9ec0037753cd55664ec5c1f lolex-1.3.1.tgz