myexperiment-rest 0.2.6
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGES +9 -0
- data/LICENSE +23 -0
- data/README +33 -0
- data/Rakefile +45 -0
- data/bin/get_workflow_data.rb +31 -0
- data/doc/classes/MyExperimentREST.html +113 -0
- data/doc/classes/MyExperimentREST/IOData.html +169 -0
- data/doc/classes/MyExperimentREST/IOData.src/M000003.html +20 -0
- data/doc/classes/MyExperimentREST/ReadWorkflow.html +184 -0
- data/doc/classes/MyExperimentREST/ReadWorkflow.src/M000002.html +39 -0
- data/doc/classes/MyExperimentREST/ReadWorkflow.src/M000005.html +41 -0
- data/doc/classes/MyExperimentREST/TavernaIOData.html +167 -0
- data/doc/classes/MyExperimentREST/TavernaIOData.src/M000006.html +20 -0
- data/doc/classes/MyExperimentREST/TavernaIOData.src/M000007.html +20 -0
- data/doc/classes/MyExperimentREST/TavernaWorkflow.html +209 -0
- data/doc/classes/MyExperimentREST/TavernaWorkflow.src/M000005.html +23 -0
- data/doc/classes/MyExperimentREST/TavernaWorkflow.src/M000006.html +22 -0
- data/doc/classes/MyExperimentREST/Workflow.html +172 -0
- data/doc/classes/MyExperimentREST/Workflow.src/M000001.html +21 -0
- data/doc/classes/MyExperimentREST/Workflows.html +167 -0
- data/doc/classes/MyExperimentREST/Workflows.src/M000004.html +41 -0
- data/doc/classes/TestReadWorkflow.html +167 -0
- data/doc/classes/TestReadWorkflow.src/M000001.html +18 -0
- data/doc/classes/TestReadWorkflow.src/M000002.html +24 -0
- data/doc/classes/TestReadWorkflow.src/M000003.html +20 -0
- data/doc/classes/TestReadWorkflow.src/M000004.html +20 -0
- data/doc/created.rid +1 -0
- data/doc/files/bin/get_workflow_data_rb.html +116 -0
- data/doc/files/lib/myexperiment-rest/my_experiment_rest_rb.html +110 -0
- data/doc/files/lib/myexperiment-rest/myexperiment_rest_rb.html +110 -0
- data/doc/files/lib/myexperiment-rest_rb.html +108 -0
- data/doc/files/test/test_read_workflow_rb.html +122 -0
- data/doc/fr_class_index.html +31 -0
- data/doc/fr_file_index.html +29 -0
- data/doc/fr_method_index.html +32 -0
- data/doc/index.html +24 -0
- data/doc/rdoc-style.css +208 -0
- data/doc/rdoc/classes/MyExperimentREST.html +117 -0
- data/doc/rdoc/classes/MyExperimentREST/TavernaIOData.html +178 -0
- data/doc/rdoc/classes/MyExperimentREST/TavernaWorkflow.html +223 -0
- data/doc/rdoc/classes/MyExperimentREST/Workflows.html +199 -0
- data/doc/rdoc/created.rid +1 -0
- data/doc/rdoc/files/CHANGES.html +121 -0
- data/doc/rdoc/files/LICENSE.html +133 -0
- data/doc/rdoc/files/README.html +148 -0
- data/doc/rdoc/files/lib/myexperiment-rest/myexperiment_rest_rb.html +110 -0
- data/doc/rdoc/files/lib/myexperiment-rest_rb.html +108 -0
- data/doc/rdoc/fr_class_index.html +30 -0
- data/doc/rdoc/fr_file_index.html +31 -0
- data/doc/rdoc/fr_method_index.html +29 -0
- data/doc/rdoc/index.html +24 -0
- data/doc/rdoc/rdoc-style.css +208 -0
- data/lib/myexperiment-rest.rb +5 -0
- data/lib/myexperiment-rest/myexperiment_rest.rb +146 -0
- metadata +133 -0
@@ -0,0 +1,21 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>new (MyExperimentREST::Workflow)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/myexperiment-rest/my_experiment_rest.rb, line 97</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">title</span>, <span class="ruby-identifier">description</span>, <span class="ruby-identifier">inputs</span>, <span class="ruby-identifier">outputs</span>)
|
15
|
+
<span class="ruby-ivar">@title</span> = <span class="ruby-identifier">title</span>
|
16
|
+
<span class="ruby-ivar">@description</span> = <span class="ruby-identifier">description</span>
|
17
|
+
<span class="ruby-ivar">@inputs</span> = <span class="ruby-identifier">inputs</span>
|
18
|
+
<span class="ruby-ivar">@outputs</span> = <span class="ruby-identifier">outputs</span>
|
19
|
+
<span class="ruby-keyword kw">end</span></pre>
|
20
|
+
</body>
|
21
|
+
</html>
|
@@ -0,0 +1,167 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: MyExperimentREST::Workflows</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">MyExperimentREST::Workflows</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../../files/lib/myexperiment-rest/myexperiment_rest_rb.html">
|
59
|
+
lib/myexperiment-rest/myexperiment_rest.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
<tr class="top-aligned-row">
|
66
|
+
<td><strong>Parent:</strong></td>
|
67
|
+
<td>
|
68
|
+
Object
|
69
|
+
</td>
|
70
|
+
</tr>
|
71
|
+
</table>
|
72
|
+
</div>
|
73
|
+
<!-- banner header -->
|
74
|
+
|
75
|
+
<div id="bodyContent">
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<div id="contextContent">
|
80
|
+
|
81
|
+
<div id="description">
|
82
|
+
<p>
|
83
|
+
Connects to myExperiment REST API and creates a <em><a
|
84
|
+
href="TavernaWorkflow.html">TavernaWorkflow</a></em> object.
|
85
|
+
</p>
|
86
|
+
|
87
|
+
</div>
|
88
|
+
|
89
|
+
|
90
|
+
</div>
|
91
|
+
|
92
|
+
<div id="method-list">
|
93
|
+
<h3 class="section-bar">Methods</h3>
|
94
|
+
|
95
|
+
<div class="name-list">
|
96
|
+
<a href="#M000004">read</a>
|
97
|
+
</div>
|
98
|
+
</div>
|
99
|
+
|
100
|
+
</div>
|
101
|
+
|
102
|
+
|
103
|
+
<!-- if includes -->
|
104
|
+
<div id="includes">
|
105
|
+
<h3 class="section-bar">Included Modules</h3>
|
106
|
+
|
107
|
+
<div id="includes-list">
|
108
|
+
<span class="include-name">LibXML</span>
|
109
|
+
</div>
|
110
|
+
</div>
|
111
|
+
|
112
|
+
<div id="section">
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
|
118
|
+
<div id="attribute-list">
|
119
|
+
<h3 class="section-bar">Attributes</h3>
|
120
|
+
|
121
|
+
<div class="name-list">
|
122
|
+
<table>
|
123
|
+
<tr class="top-aligned-row context-row">
|
124
|
+
<td class="context-item-name">uri</td>
|
125
|
+
<td class="context-item-value"> [R] </td>
|
126
|
+
<td class="context-item-desc"></td>
|
127
|
+
</tr>
|
128
|
+
</table>
|
129
|
+
</div>
|
130
|
+
</div>
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
<!-- if method_list -->
|
135
|
+
<div id="methods">
|
136
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
137
|
+
|
138
|
+
<div id="method-M000004" class="method-detail">
|
139
|
+
<a name="M000004"></a>
|
140
|
+
|
141
|
+
<div class="method-heading">
|
142
|
+
<a href="Workflows.src/M000004.html" target="Code" class="method-signature"
|
143
|
+
onclick="popupCode('Workflows.src/M000004.html');return false;">
|
144
|
+
<span class="method-name">read</span><span class="method-args">(uri)</span>
|
145
|
+
</a>
|
146
|
+
</div>
|
147
|
+
|
148
|
+
<div class="method-description">
|
149
|
+
<p>
|
150
|
+
Requires the URI of the workflow in the repository as a String.
|
151
|
+
</p>
|
152
|
+
</div>
|
153
|
+
</div>
|
154
|
+
|
155
|
+
|
156
|
+
</div>
|
157
|
+
|
158
|
+
|
159
|
+
</div>
|
160
|
+
|
161
|
+
|
162
|
+
<div id="validator-badges">
|
163
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
164
|
+
</div>
|
165
|
+
|
166
|
+
</body>
|
167
|
+
</html>
|
@@ -0,0 +1,41 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>read (MyExperimentREST::Workflows)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/myexperiment-rest/myexperiment_rest.rb, line 19</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">read</span>(<span class="ruby-identifier">uri</span>)
|
15
|
+
|
16
|
+
<span class="ruby-identifier">workflow_id</span> = <span class="ruby-value str">''</span>
|
17
|
+
<span class="ruby-identifier">workflow_version</span> = <span class="ruby-value str">''</span>
|
18
|
+
|
19
|
+
<span class="ruby-comment cmt"># Get workflow id</span>
|
20
|
+
<span class="ruby-identifier">uri_id</span> = <span class="ruby-identifier">uri</span>.<span class="ruby-identifier">match</span>(<span class="ruby-regexp re">/workflows\/(\d+)/</span>)
|
21
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">uri_id</span> <span class="ruby-operator">!=</span> <span class="ruby-keyword kw">nil</span>
|
22
|
+
<span class="ruby-identifier">workflow_id</span> = <span class="ruby-identifier">uri_id</span>[<span class="ruby-value">1</span>]
|
23
|
+
<span class="ruby-keyword kw">else</span>
|
24
|
+
<span class="ruby-identifier">raise</span> <span class="ruby-value str">"Could not match workflow id."</span>
|
25
|
+
<span class="ruby-keyword kw">end</span>
|
26
|
+
|
27
|
+
<span class="ruby-comment cmt"># Get workflow version if it exists</span>
|
28
|
+
<span class="ruby-identifier">uri_version</span> = <span class="ruby-identifier">uri</span>.<span class="ruby-identifier">match</span>(<span class="ruby-regexp re">/version=(\d+)/</span>)
|
29
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">uri_version</span> <span class="ruby-operator">!=</span> <span class="ruby-keyword kw">nil</span>
|
30
|
+
<span class="ruby-identifier">workflow_version</span> = <span class="ruby-identifier">uri_version</span>[<span class="ruby-value">1</span>]
|
31
|
+
<span class="ruby-keyword kw">end</span>
|
32
|
+
|
33
|
+
<span class="ruby-comment cmt"># Get workflow resource information -- if version is empty it returns the current version</span>
|
34
|
+
<span class="ruby-identifier">response</span> = <span class="ruby-constant">RestClient</span>.<span class="ruby-identifier">get</span>(<span class="ruby-value str">'http://www.myexperiment.org/workflow.xml'</span>, {<span class="ruby-identifier">:params</span> =<span class="ruby-operator">></span> {<span class="ruby-value str">'id'</span> =<span class="ruby-operator">></span> <span class="ruby-node">"#{workflow_id}"</span>,
|
35
|
+
<span class="ruby-value str">'version'</span> =<span class="ruby-operator">></span> <span class="ruby-node">"#{workflow_version}"</span>,
|
36
|
+
<span class="ruby-value str">'elements'</span> =<span class="ruby-operator">></span> <span class="ruby-value str">'title,description,content-uri,components'</span>} } )
|
37
|
+
|
38
|
+
<span class="ruby-identifier">populate_workflow</span>(<span class="ruby-identifier">response</span>)
|
39
|
+
<span class="ruby-keyword kw">end</span></pre>
|
40
|
+
</body>
|
41
|
+
</html>
|
@@ -0,0 +1,167 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: TestReadWorkflow</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">TestReadWorkflow</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/test/test_read_workflow_rb.html">
|
59
|
+
test/test_read_workflow.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
<tr class="top-aligned-row">
|
66
|
+
<td><strong>Parent:</strong></td>
|
67
|
+
<td>
|
68
|
+
Test::Unit::TestCase
|
69
|
+
</td>
|
70
|
+
</tr>
|
71
|
+
</table>
|
72
|
+
</div>
|
73
|
+
<!-- banner header -->
|
74
|
+
|
75
|
+
<div id="bodyContent">
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<div id="contextContent">
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
</div>
|
84
|
+
|
85
|
+
<div id="method-list">
|
86
|
+
<h3 class="section-bar">Methods</h3>
|
87
|
+
|
88
|
+
<div class="name-list">
|
89
|
+
<a href="#M000001">setup</a>
|
90
|
+
<a href="#M000002">test_workflow_values</a>
|
91
|
+
<a href="#M000003">test_workflows_ios</a>
|
92
|
+
</div>
|
93
|
+
</div>
|
94
|
+
|
95
|
+
</div>
|
96
|
+
|
97
|
+
|
98
|
+
<!-- if includes -->
|
99
|
+
|
100
|
+
<div id="section">
|
101
|
+
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
|
106
|
+
|
107
|
+
|
108
|
+
|
109
|
+
<!-- if method_list -->
|
110
|
+
<div id="methods">
|
111
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
112
|
+
|
113
|
+
<div id="method-M000001" class="method-detail">
|
114
|
+
<a name="M000001"></a>
|
115
|
+
|
116
|
+
<div class="method-heading">
|
117
|
+
<a href="TestReadWorkflow.src/M000001.html" target="Code" class="method-signature"
|
118
|
+
onclick="popupCode('TestReadWorkflow.src/M000001.html');return false;">
|
119
|
+
<span class="method-name">setup</span><span class="method-args">()</span>
|
120
|
+
</a>
|
121
|
+
</div>
|
122
|
+
|
123
|
+
<div class="method-description">
|
124
|
+
</div>
|
125
|
+
</div>
|
126
|
+
|
127
|
+
<div id="method-M000002" class="method-detail">
|
128
|
+
<a name="M000002"></a>
|
129
|
+
|
130
|
+
<div class="method-heading">
|
131
|
+
<a href="TestReadWorkflow.src/M000002.html" target="Code" class="method-signature"
|
132
|
+
onclick="popupCode('TestReadWorkflow.src/M000002.html');return false;">
|
133
|
+
<span class="method-name">test_workflow_values</span><span class="method-args">()</span>
|
134
|
+
</a>
|
135
|
+
</div>
|
136
|
+
|
137
|
+
<div class="method-description">
|
138
|
+
</div>
|
139
|
+
</div>
|
140
|
+
|
141
|
+
<div id="method-M000003" class="method-detail">
|
142
|
+
<a name="M000003"></a>
|
143
|
+
|
144
|
+
<div class="method-heading">
|
145
|
+
<a href="TestReadWorkflow.src/M000003.html" target="Code" class="method-signature"
|
146
|
+
onclick="popupCode('TestReadWorkflow.src/M000003.html');return false;">
|
147
|
+
<span class="method-name">test_workflows_ios</span><span class="method-args">()</span>
|
148
|
+
</a>
|
149
|
+
</div>
|
150
|
+
|
151
|
+
<div class="method-description">
|
152
|
+
</div>
|
153
|
+
</div>
|
154
|
+
|
155
|
+
|
156
|
+
</div>
|
157
|
+
|
158
|
+
|
159
|
+
</div>
|
160
|
+
|
161
|
+
|
162
|
+
<div id="validator-badges">
|
163
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
164
|
+
</div>
|
165
|
+
|
166
|
+
</body>
|
167
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>setup (TestReadWorkflow)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File test/test_read_workflow.rb, line 11</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">setup</span>
|
15
|
+
<span class="ruby-ivar">@wkf</span> = <span class="ruby-constant">Workflows</span>.<span class="ruby-identifier">new</span>.<span class="ruby-identifier">read</span>(<span class="ruby-value str">'http://www.myexperiment.org/workflows/74/download/bioaid_proteindiscovery_221429.xml?version=3'</span>)
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,24 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>test_workflow_values (TestReadWorkflow)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File test/test_read_workflow.rb, line 15</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">test_workflow_values</span>
|
15
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value str">'myexperiment'</span>, <span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">input_type</span>, <span class="ruby-value str">"Workflow's input type not properly initialized!"</span>
|
16
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value str">'http://www.myexperiment.org/workflows/74/download/bioaid_proteindiscovery_221429.xml'</span>, <span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">xml_uri</span>, <span class="ruby-value str">"Workflow's XML URI not properly initialized!"</span>
|
17
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value str">'BioAID_ProteinDiscovery'</span>, <span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">title</span>, <span class="ruby-value str">"Workflow's title not properly initialized!"</span>
|
18
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value str">'<p>The workflow extracts protein names from documents retrieved from MedLine based on a user Query (cf Apache Lucene syntax). The protein names are filtered by checking if there exists a valid UniProt ID for the given protein name.</p>'</span>,
|
19
|
+
<span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">description</span>, <span class="ruby-value str">"Workflow's description not properly initialized!"</span>
|
20
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value">2</span>, <span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">inputs</span>.<span class="ruby-identifier">size</span>, <span class="ruby-value str">"Workflow's inputs size not properly initialized!"</span>
|
21
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value">2</span>, <span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">outputs</span>.<span class="ruby-identifier">size</span>, <span class="ruby-value str">"Workflow's outputs size not properly initialized!"</span>
|
22
|
+
<span class="ruby-keyword kw">end</span></pre>
|
23
|
+
</body>
|
24
|
+
</html>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>test_workflows_ios (TestReadWorkflow)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File test/test_read_workflow.rb, line 25</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">test_workflows_ios</span>
|
15
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value str">'Query'</span>, <span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">inputs</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">name</span>, <span class="ruby-value str">"Workflow's first input name not properly initialized!"</span>
|
16
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value str">'Maximum number of documents to extract proteins from.'</span>, <span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">inputs</span>[<span class="ruby-value">1</span>].<span class="ruby-identifier">descriptions</span>[<span class="ruby-value">1</span>], <span class="ruby-value str">"Workflow's second input's description not properly initialized!"</span>
|
17
|
+
<span class="ruby-identifier">assert_equal</span> <span class="ruby-value str">'"transmembrane proteins" AND amyloid'</span>, <span class="ruby-ivar">@wkf</span>.<span class="ruby-identifier">inputs</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">examples</span>[<span class="ruby-value">0</span>], <span class="ruby-value str">"Workflow's first input's example not properly initialized!"</span>
|
18
|
+
<span class="ruby-keyword kw">end</span></pre>
|
19
|
+
</body>
|
20
|
+
</html>
|