openwferu 0.9.8 → 0.9.9
Sign up to get free protection for your applications and to get access to all the features.
- data/README.txt +4 -5
- data/lib/openwfe/engine/engine.rb +14 -14
- data/lib/openwfe/expool/expressionpool.rb +60 -45
- data/lib/openwfe/expool/expstorage.rb +1 -1
- data/lib/openwfe/expressions/condition.rb +47 -34
- data/lib/openwfe/expressions/environment.rb +29 -7
- data/lib/openwfe/expressions/expressionmap.rb +16 -1
- data/lib/openwfe/expressions/fe_concurrence.rb +142 -55
- data/lib/openwfe/expressions/fe_cursor.rb +146 -41
- data/lib/openwfe/expressions/fe_define.rb +52 -35
- data/lib/openwfe/expressions/fe_filter.rb +129 -0
- data/lib/openwfe/expressions/fe_filter_definition.rb +170 -0
- data/lib/openwfe/expressions/fe_iterator.rb +23 -10
- data/lib/openwfe/expressions/fe_losfor.rb +7 -6
- data/lib/openwfe/expressions/fe_participant.rb +19 -9
- data/lib/openwfe/expressions/fe_raw.rb +11 -16
- data/lib/openwfe/expressions/fe_save.rb +225 -0
- data/lib/openwfe/expressions/fe_sequence.rb +15 -10
- data/lib/openwfe/expressions/fe_subprocess.rb +0 -6
- data/lib/openwfe/expressions/fe_value.rb +7 -19
- data/lib/openwfe/expressions/filter.rb +104 -0
- data/lib/openwfe/expressions/flowexpression.rb +102 -36
- data/lib/openwfe/expressions/merge.rb +80 -0
- data/lib/openwfe/expressions/raw_prog.rb +21 -18
- data/lib/openwfe/filterdef.rb +259 -0
- data/lib/openwfe/flowexpressionid.rb +36 -3
- data/lib/openwfe/participants/participants.rb +7 -1
- data/lib/openwfe/rest/xmlcodec.rb +1 -1
- data/lib/openwfe/util/dollar.rb +4 -2
- data/lib/openwfe/util/scheduler.rb +3 -1
- data/lib/openwfe/util/sqs.rb +1 -2
- data/lib/openwfe/utils.rb +13 -0
- data/lib/openwfe/version.rb +1 -1
- data/lib/openwfe/workitem.rb +1 -1
- data/test/filter_test.rb +109 -0
- data/test/flowtestbase.rb +12 -1
- data/test/ft_11_ppd.rb +13 -1
- data/test/ft_11b_ppd.rb +45 -0
- data/test/ft_17_condition.rb +1 -1
- data/test/ft_2b_concurrence.rb +24 -0
- data/test/ft_2c_concurrence.rb +22 -1
- data/test/ft_3_equals.rb +26 -0
- data/test/ft_42_environments.rb +78 -0
- data/test/ft_43_pat10.rb +109 -0
- data/test/ft_44_save.rb +81 -0
- data/test/ft_44b_restore.rb +159 -0
- data/test/ft_45_citerator.rb +104 -0
- data/test/ft_46_pparams.rb +62 -0
- data/test/ft_47_filter.rb +165 -0
- data/test/ft_48_fe_filter.rb +91 -0
- data/test/ft_49_condition.rb +65 -0
- data/test/ft_50_xml_attribute.rb +89 -0
- data/test/ft_9_cursor.rb +36 -6
- data/test/ft_tests.rb +11 -1
- data/test/misc_test.rb +8 -0
- data/test/rake_qtest.rb +2 -2
- data/test/rutest_utils.rb +6 -1
- data/test/sec_test.rb +2 -2
- metadata +20 -2
data/test/ft_9_cursor.rb
CHANGED
@@ -7,6 +7,7 @@
|
|
7
7
|
# Tue Jan 2 13:14:37 JST 2007
|
8
8
|
#
|
9
9
|
|
10
|
+
require 'openwfe/def'
|
10
11
|
require 'flowtestbase'
|
11
12
|
|
12
13
|
|
@@ -20,7 +21,7 @@ class FlowTest9 < Test::Unit::TestCase
|
|
20
21
|
#end
|
21
22
|
|
22
23
|
def test_cursor_0
|
23
|
-
dotest(
|
24
|
+
dotest(
|
24
25
|
'<process-definition name="'+name_of_test+'''" revision="0">
|
25
26
|
<cursor>
|
26
27
|
<print>a</print>
|
@@ -32,7 +33,7 @@ b""")
|
|
32
33
|
end
|
33
34
|
|
34
35
|
def test_cursor_1
|
35
|
-
dotest(
|
36
|
+
dotest(
|
36
37
|
'<process-definition name="'+name_of_test+'''" revision="0">
|
37
38
|
<cursor>
|
38
39
|
<print>a</print>
|
@@ -46,7 +47,7 @@ b""")
|
|
46
47
|
end
|
47
48
|
|
48
49
|
def test_cursor_2
|
49
|
-
dotest(
|
50
|
+
dotest(
|
50
51
|
'<process-definition name="'+name_of_test+'''" revision="0">
|
51
52
|
<cursor>
|
52
53
|
<print>a</print>
|
@@ -63,7 +64,7 @@ b""")
|
|
63
64
|
#
|
64
65
|
# ZigZag test
|
65
66
|
#
|
66
|
-
dotest(
|
67
|
+
dotest(
|
67
68
|
'<process-definition name="'+name_of_test+'''" revision="0">
|
68
69
|
<cursor>
|
69
70
|
<print>a</print>
|
@@ -80,7 +81,7 @@ c""")
|
|
80
81
|
end
|
81
82
|
|
82
83
|
def test_cursor_3
|
83
|
-
dotest(
|
84
|
+
dotest(
|
84
85
|
'<process-definition name="'+name_of_test+'''" revision="0">
|
85
86
|
<cursor>
|
86
87
|
<print>a</print>
|
@@ -94,7 +95,7 @@ c""")
|
|
94
95
|
end
|
95
96
|
|
96
97
|
def test_cursor_4
|
97
|
-
dotest(
|
98
|
+
dotest(
|
98
99
|
'<process-definition name="'+name_of_test+'''" revision="0">
|
99
100
|
<sequence>
|
100
101
|
<cursor>
|
@@ -111,5 +112,34 @@ c
|
|
111
112
|
d""")
|
112
113
|
end
|
113
114
|
|
115
|
+
def test_cursor_5
|
116
|
+
dotest(
|
117
|
+
'<process-definition name="'+name_of_test+'''" revision="0">
|
118
|
+
<cursor>
|
119
|
+
<print>a</print>
|
120
|
+
<skip>2</skip>
|
121
|
+
<print>b</print>
|
122
|
+
<print>c</print>
|
123
|
+
</cursor>
|
124
|
+
</process-definition>''',
|
125
|
+
"""a
|
126
|
+
c""")
|
127
|
+
end
|
128
|
+
|
129
|
+
class TestCursor6 < OpenWFE::ProcessDefinition
|
130
|
+
cursor do
|
131
|
+
_print "a"
|
132
|
+
skip "2"
|
133
|
+
_print "b"
|
134
|
+
_print "c"
|
135
|
+
skip 2
|
136
|
+
_print "d"
|
137
|
+
end
|
138
|
+
end
|
139
|
+
|
140
|
+
def test_cursor_6
|
141
|
+
dotest(TestCursor6, "a\nc")
|
142
|
+
end
|
143
|
+
|
114
144
|
end
|
115
145
|
|
data/test/ft_tests.rb
CHANGED
@@ -27,6 +27,7 @@ require 'ft_9_cursor'
|
|
27
27
|
require 'ft_10_loop'
|
28
28
|
require 'ft_10b_loop2'
|
29
29
|
require 'ft_11_ppd'
|
30
|
+
require 'ft_11b_ppd'
|
30
31
|
require 'ft_12_blockparticipant'
|
31
32
|
require 'ft_14_subprocess'
|
32
33
|
require 'ft_14b_subprocess'
|
@@ -43,7 +44,6 @@ require 'ft_24_def'
|
|
43
44
|
require 'ft_25_cancel'
|
44
45
|
require 'ft_27_getflowpos'
|
45
46
|
require 'ft_28_fileparticipant'
|
46
|
-
require 'ft_30_socketlistener'
|
47
47
|
require 'ft_31_flowname'
|
48
48
|
require 'ft_34_cancelwfid'
|
49
49
|
require 'ft_35_localdefs'
|
@@ -53,6 +53,16 @@ require 'ft_38_tag'
|
|
53
53
|
require 'ft_39_reserve'
|
54
54
|
require 'ft_40_defined'
|
55
55
|
require 'ft_41_case'
|
56
|
+
require 'ft_42_environments'
|
57
|
+
require 'ft_43_pat10'
|
58
|
+
require 'ft_44_save'
|
59
|
+
require 'ft_44b_restore'
|
60
|
+
require 'ft_45_citerator'
|
61
|
+
require 'ft_46_pparams'
|
62
|
+
require 'ft_47_filter'
|
63
|
+
require 'ft_48_fe_filter'
|
64
|
+
require 'ft_49_condition'
|
65
|
+
require 'ft_50_xml_attribute'
|
56
66
|
|
57
67
|
require 'ft_32_journal'
|
58
68
|
|
data/test/misc_test.rb
CHANGED
@@ -8,6 +8,8 @@
|
|
8
8
|
#
|
9
9
|
|
10
10
|
require 'test/unit'
|
11
|
+
require 'rexml/document'
|
12
|
+
|
11
13
|
require 'openwfe/utils'
|
12
14
|
require 'openwfe/expressions/fe_define'
|
13
15
|
require 'openwfe/expressions/expressionmap'
|
@@ -70,6 +72,12 @@ class MiscTest < Test::Unit::TestCase
|
|
70
72
|
"dup() utility not working"
|
71
73
|
end
|
72
74
|
|
75
|
+
def test_dup_1
|
76
|
+
d = REXML::Document.new("<document/>")
|
77
|
+
d1 = OpenWFE::fulldup(d)
|
78
|
+
assert d.object_id != d1.object_id
|
79
|
+
end
|
80
|
+
|
73
81
|
private
|
74
82
|
|
75
83
|
class A
|
data/test/rake_qtest.rb
CHANGED
@@ -14,6 +14,7 @@
|
|
14
14
|
require 'fei_test'
|
15
15
|
require 'wfid_test'
|
16
16
|
require 'wi_test'
|
17
|
+
require 'filter_test'
|
17
18
|
require 'dollar_test'
|
18
19
|
require 'misc_test'
|
19
20
|
require 'hash_test'
|
@@ -24,7 +25,6 @@ require 'file_persistence_test'
|
|
24
25
|
require 'cronline_test'
|
25
26
|
require 'csv_test'
|
26
27
|
require 'safely_test'
|
27
|
-
#require 'model_test'
|
28
28
|
require 'kotoba_test'
|
29
29
|
require 'expmap_test'
|
30
30
|
|
@@ -35,7 +35,7 @@ require 'ft_tests'
|
|
35
35
|
#
|
36
36
|
# all the 'ft' tests are required in 'ft_tests.rb'
|
37
37
|
|
38
|
-
|
38
|
+
require 'ft_30_socketlistener'
|
39
39
|
|
40
40
|
require 'hparticipant_test'
|
41
41
|
require 'timeout_test'
|
data/test/rutest_utils.rb
CHANGED
@@ -6,7 +6,8 @@
|
|
6
6
|
# Mon Oct 9 22:19:44 JST 2006
|
7
7
|
#
|
8
8
|
|
9
|
-
require 'openwfe/
|
9
|
+
require 'openwfe/version'
|
10
|
+
#require 'openwfe/rudefinitions'
|
10
11
|
|
11
12
|
|
12
13
|
class Tracer
|
@@ -27,6 +28,10 @@ class Tracer
|
|
27
28
|
def clear
|
28
29
|
@trace = ""
|
29
30
|
end
|
31
|
+
|
32
|
+
def puts s
|
33
|
+
@trace << "#{s}\n"
|
34
|
+
end
|
30
35
|
end
|
31
36
|
|
32
37
|
def new_fei ()
|
data/test/sec_test.rb
CHANGED
@@ -129,13 +129,13 @@ class SecTest < Test::Unit::TestCase
|
|
129
129
|
|
130
130
|
engine.launch(OpenWFE::LaunchItem.new(def0))
|
131
131
|
|
132
|
-
assert_equal value, "
|
132
|
+
assert_equal value, "4_"
|
133
133
|
|
134
134
|
engine.ac[:ruby_eval_allowed] = true
|
135
135
|
|
136
136
|
engine.launch(OpenWFE::LaunchItem.new(def0))
|
137
137
|
|
138
|
-
assert_equal value, "
|
138
|
+
assert_equal value, "4_35"
|
139
139
|
|
140
140
|
engine.stop
|
141
141
|
end
|
metadata
CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.0
|
|
3
3
|
specification_version: 1
|
4
4
|
name: openwferu
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.9.
|
7
|
-
date: 2007-04-
|
6
|
+
version: 0.9.9
|
7
|
+
date: 2007-04-16 00:00:00 +09:00
|
8
8
|
summary: an open source ruby workflow and bpm engine
|
9
9
|
require_paths:
|
10
10
|
- lib
|
@@ -40,6 +40,7 @@ files:
|
|
40
40
|
- lib/openwfe/exceptions.rb
|
41
41
|
- lib/openwfe/expool
|
42
42
|
- lib/openwfe/expressions
|
43
|
+
- lib/openwfe/filterdef.rb
|
43
44
|
- lib/openwfe/flowexpressionid.rb
|
44
45
|
- lib/openwfe/listeners
|
45
46
|
- lib/openwfe/logging.rb
|
@@ -73,6 +74,8 @@ files:
|
|
73
74
|
- lib/openwfe/expressions/fe_define.rb
|
74
75
|
- lib/openwfe/expressions/fe_do.rb
|
75
76
|
- lib/openwfe/expressions/fe_equals.rb
|
77
|
+
- lib/openwfe/expressions/fe_filter.rb
|
78
|
+
- lib/openwfe/expressions/fe_filter_definition.rb
|
76
79
|
- lib/openwfe/expressions/fe_fqv.rb
|
77
80
|
- lib/openwfe/expressions/fe_if.rb
|
78
81
|
- lib/openwfe/expressions/fe_iterator.rb
|
@@ -81,13 +84,16 @@ files:
|
|
81
84
|
- lib/openwfe/expressions/fe_participant.rb
|
82
85
|
- lib/openwfe/expressions/fe_raw.rb
|
83
86
|
- lib/openwfe/expressions/fe_reserve.rb
|
87
|
+
- lib/openwfe/expressions/fe_save.rb
|
84
88
|
- lib/openwfe/expressions/fe_sequence.rb
|
85
89
|
- lib/openwfe/expressions/fe_sleep.rb
|
86
90
|
- lib/openwfe/expressions/fe_subprocess.rb
|
87
91
|
- lib/openwfe/expressions/fe_value.rb
|
88
92
|
- lib/openwfe/expressions/fe_wait.rb
|
89
93
|
- lib/openwfe/expressions/fe_when.rb
|
94
|
+
- lib/openwfe/expressions/filter.rb
|
90
95
|
- lib/openwfe/expressions/flowexpression.rb
|
96
|
+
- lib/openwfe/expressions/merge.rb
|
91
97
|
- lib/openwfe/expressions/raw_prog.rb
|
92
98
|
- lib/openwfe/expressions/raw_xml.rb
|
93
99
|
- lib/openwfe/expressions/simplerep.rb
|
@@ -140,6 +146,7 @@ files:
|
|
140
146
|
- test/expmap_test.rb
|
141
147
|
- test/fei_test.rb
|
142
148
|
- test/file_persistence_test.rb
|
149
|
+
- test/filter_test.rb
|
143
150
|
- test/flowtestbase.rb
|
144
151
|
- test/ft_0.rb
|
145
152
|
- test/ft_0b_sequence.rb
|
@@ -148,6 +155,7 @@ files:
|
|
148
155
|
- test/ft_10_loop.rb
|
149
156
|
- test/ft_10b_loop2.rb
|
150
157
|
- test/ft_11_ppd.rb
|
158
|
+
- test/ft_11b_ppd.rb
|
151
159
|
- test/ft_12_blockparticipant.rb
|
152
160
|
- test/ft_13_eno.rb
|
153
161
|
- test/ft_14_subprocess.rb
|
@@ -188,7 +196,17 @@ files:
|
|
188
196
|
- test/ft_3_equals.rb
|
189
197
|
- test/ft_40_defined.rb
|
190
198
|
- test/ft_41_case.rb
|
199
|
+
- test/ft_42_environments.rb
|
200
|
+
- test/ft_43_pat10.rb
|
201
|
+
- test/ft_44_save.rb
|
202
|
+
- test/ft_44b_restore.rb
|
203
|
+
- test/ft_45_citerator.rb
|
204
|
+
- test/ft_46_pparams.rb
|
205
|
+
- test/ft_47_filter.rb
|
206
|
+
- test/ft_48_fe_filter.rb
|
207
|
+
- test/ft_49_condition.rb
|
191
208
|
- test/ft_4_misc.rb
|
209
|
+
- test/ft_50_xml_attribute.rb
|
192
210
|
- test/ft_5_time.rb
|
193
211
|
- test/ft_6_lambda.rb
|
194
212
|
- test/ft_7_lose.rb
|