Package: lua-sec / 0.6-3

0001-test.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
From: Enrico Tassi <gareuselesinge@debian.org>
Date: Fri, 9 Aug 2013 17:47:14 +0200
Subject: test

Gbp-Pq: Name 0001-test.patch
---
 test.lua |  2 ++
 test.sh  | 13 +++++++++++++
 2 files changed, 15 insertions(+)
 create mode 100644 test.lua
 create mode 100644 test.sh

diff --git a/test.lua b/test.lua
new file mode 100644
index 0000000..b80247f
--- /dev/null
+++ b/test.lua
@@ -0,0 +1,2 @@
+rc=os.execute("sh test.sh")
+if rc == true then os.exit(0) elseif rc== 0 then os.exit(0) else os.exit(1); end
diff --git a/test.sh b/test.sh
new file mode 100644
index 0000000..b14082e
--- /dev/null
+++ b/test.sh
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+set -e
+set -x
+
+cd samples/oneshot/
+
+lua server.lua &
+sleep 1
+ret=0
+lua client.lua || ret=$?
+kill -9 %1 || true
+exit $ret