diff --git a/nodejs-tough-cookie-expiry.patch b/nodejs-tough-cookie-expiry.patch new file mode 100644 index 0000000000000000000000000000000000000000..46fd90c61ee2d382251e86915cdd080b9b89ff16 --- /dev/null +++ b/nodejs-tough-cookie-expiry.patch @@ -0,0 +1,22 @@ +commit 436ef58406c9ed219ae7f9778288645054d3e3a4 +Author: Tom Hughes +Date: Sat Aug 12 15:29:36 2017 +0100 + + Push expiry date further into the future + + This test had started failed because we have now passed the + specified expiry date, so push it further into the future. + +diff --git a/test/ietf_data/parser.json b/test/ietf_data/parser.json +index 783f660..c40ad54 100644 +--- a/test/ietf_data/parser.json ++++ b/test/ietf_data/parser.json +@@ -21,7 +21,7 @@ + "test": "0003", + "received": [ + "foo=bar; Expires=Fri, 07 Aug 2007 08:04:19 GMT", +- "foo2=bar2; Expires=Fri, 07 Aug 2017 08:04:19 GMT" ++ "foo2=bar2; Expires=Fri, 07 Aug 2027 08:04:19 GMT" + ], + "sent": [ + { "name": "foo2", "value": "bar2" } diff --git a/nodejs-tough-cookie.spec b/nodejs-tough-cookie.spec new file mode 100644 index 0000000000000000000000000000000000000000..caa182a2d148bcdcce7ebc9f31959a676a9b3d97 --- /dev/null +++ b/nodejs-tough-cookie.spec @@ -0,0 +1,48 @@ +%global enable_tests 1 +%global srcname tough-cookie +Name: nodejs-%{srcname} +Version: 2.3.2 +Release: 1 +Summary: RFC6265 Cookies and Cookie Jar for Node.js +License: BSD and MPLv2.0 +URL: https://www.npmjs.com/package/tough-cookie +Source0: https://github.com/salesforce/tough-cookie/archive/v%{version}/tough-cookie-%{version}.tar.gz +# https://github.com/salesforce/tough-cookie/pull/91 +Patch0: nodejs-tough-cookie-expiry.patch +BuildArch: noarch +ExclusiveArch: %{nodejs_arches} noarch +BuildRequires: nodejs-packaging +%if 0%{?enable_tests} +BuildRequires: npm(async) npm(string.prototype.repeat) npm(vows) +%endif +%description +%{summary}. + +%prep +%autosetup -p 1 -n %{srcname}-%{version} +%nodejs_fixdep punycode "^2.0.0" +rm -rf node_modules + +%build +#nothing to do + +%install +mkdir -p %{buildroot}%{nodejs_sitelib}/%{srcname} +cp -pr package.json lib/ \ + %{buildroot}%{nodejs_sitelib}/%{srcname} +%nodejs_symlink_deps +%if 0%{?enable_tests} + +%check +%nodejs_symlink_deps --check +vows --spec test/*_test.js +%endif + +%files +%doc README.md +%license LICENSE +%{nodejs_sitelib}/%{srcname} + +%changelog +* Tue Aug 11 2020 wutao - 2.3.2-1 +- package init diff --git a/nodejs-tough-cookie.yaml b/nodejs-tough-cookie.yaml new file mode 100644 index 0000000000000000000000000000000000000000..5198febae785e332d692406367b0505903564b1f --- /dev/null +++ b/nodejs-tough-cookie.yaml @@ -0,0 +1,4 @@ +version_control: github +src_repo: salesforce/tough-cookie +tag_prefix: "^v" +seperator: "." diff --git a/tough-cookie-2.3.2.tar.gz b/tough-cookie-2.3.2.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..a2ecddcf0d3ddd2bd20ec17f93fcb4e1af8cb254 Binary files /dev/null and b/tough-cookie-2.3.2.tar.gz differ