SHA256
10
0
forked from pool/lua-luv

- Better version of the patch, based upon the upstream advice.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/lua-luv?expand=0&rev=17
This commit is contained in:
2020-04-11 07:01:55 +00:00
committed by Git OBS Bridge
parent c4410c613c
commit a60bd34565
3 changed files with 16 additions and 31 deletions

View File

@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Sat Apr 11 07:01:18 UTC 2020 - Matej Cepl <mcepl@suse.com>
- Better version of the patch, based upon the upstream advice.
-------------------------------------------------------------------
Wed Apr 8 12:10:44 UTC 2020 - Matej Cepl <mcepl@suse.com>

View File

@@ -119,10 +119,7 @@ project.
%prep
echo "Name is %{name}, Flavor is %{flavor}"
%setup -q -n %{mod_name}-%{upver}
# gh#luvit/luv#473
%if 0%{?sle_version}
%patch0 -p1
%endif
%autopatch -p1
# Remove bundled dependencies
rm -rf deps

View File

@@ -1,31 +1,14 @@
--- a/tests/test-thread.lua
+++ b/tests/test-thread.lua
@@ -58,28 +58,4 @@ return require('lib/tap')(function (test
assert(elapsed >= delay, "elapsed should be at least delay ")
@@ -59,6 +59,11 @@ return require('lib/tap')(function (test
end)
- test("test thread create with options table", function(print, p, expect, uv)
- local delay = 100
- uv.update_time()
- local before = uv.now()
- local args = {delay, 'string', nil, false, 5, "helloworld"}
- local unpack = unpack or table.unpack
- uv.new_thread({stack_size=0}, function(delay,s,null,bool,five,hw)
- assert(type(delay) == "number")
- assert(type(s) == "string")
- assert(null == nil)
- assert(bool == false)
- assert(five == 5)
- assert(hw == 'helloworld')
- require('luv').sleep(delay)
- end, unpack(args)):join()
- uv.update_time()
- local elapsed = uv.now() - before
- p({
- delay = delay,
- elapsed = elapsed
- })
- assert(elapsed >= 100, "elapsed should be at least delay ")
- end)
-
end)
test("test thread create with options table", function(print, p, expect, uv)
+ local version = 0x10000 + 26*0x100 + 0
+ if uv.version() < version then
+ print("skipped, requires libuv >= 1.26.0")
+ return
+ end
local delay = 100
uv.update_time()
local before = uv.now()