friendly-cukes 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (90) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +14 -0
  3. data/DETAILED_DESCRIPTION.md +235 -0
  4. data/Gemfile +17 -0
  5. data/LICENSE.txt +22 -0
  6. data/README.md +108 -0
  7. data/Rakefile +2 -0
  8. data/bin/build-extractor +69 -0
  9. data/bin/friendly-cukes +48 -0
  10. data/friendly-cukes.gemspec +41 -0
  11. data/lib/friendly/build_extractor.rb +647 -0
  12. data/lib/friendly/cukes.rb +29 -0
  13. data/lib/friendly/cukes/framework/Gemfile +16 -0
  14. data/lib/friendly/cukes/framework/Gemfile.lock +113 -0
  15. data/lib/friendly/cukes/framework/Rakefile.rb +19 -0
  16. data/lib/friendly/cukes/framework/config/config.yml +87 -0
  17. data/lib/friendly/cukes/framework/config/cucumber.yml +49 -0
  18. data/lib/friendly/cukes/framework/coverage/.last_run.json +5 -0
  19. data/lib/friendly/cukes/framework/coverage/.resultset.json +3519 -0
  20. data/lib/friendly/cukes/framework/coverage/.resultset.json.lock +0 -0
  21. data/lib/friendly/cukes/framework/coverage/rcov/assets/0.2.3/jquery-1.3.2.min.js +19 -0
  22. data/lib/friendly/cukes/framework/coverage/rcov/assets/0.2.3/jquery.tablesorter.min.js +15 -0
  23. data/lib/friendly/cukes/framework/coverage/rcov/assets/0.2.3/print.css +12 -0
  24. data/lib/friendly/cukes/framework/coverage/rcov/assets/0.2.3/rcov.js +42 -0
  25. data/lib/friendly/cukes/framework/coverage/rcov/assets/0.2.3/screen.css +270 -0
  26. data/lib/friendly/cukes/framework/coverage/rcov/index.html +392 -0
  27. data/lib/friendly/cukes/framework/coverage/rcov/library-app_init-app_driver_rb.html +98 -0
  28. data/lib/friendly/cukes/framework/coverage/rcov/library-app_utils-data_file_names_rb.html +65 -0
  29. data/lib/friendly/cukes/framework/coverage/rcov/library-app_utils-page_utils_rb.html +533 -0
  30. data/lib/friendly/cukes/framework/coverage/rcov/library-generic-create_log_rb.html +521 -0
  31. data/lib/friendly/cukes/framework/coverage/rcov/library-generic-custom_html_report_rb.html +2522 -0
  32. data/lib/friendly/cukes/framework/coverage/rcov/library-generic-datetime_library_rb.html +296 -0
  33. data/lib/friendly/cukes/framework/coverage/rcov/library-generic-file_library_rb.html +995 -0
  34. data/lib/friendly/cukes/framework/coverage/rcov/library-generic-performance_report_rb.html +1613 -0
  35. data/lib/friendly/cukes/framework/coverage/rcov/library-generic-read_from_yml_rb.html +944 -0
  36. data/lib/friendly/cukes/framework/coverage/rcov/object_repository-desktop-gem_search_rb.html +773 -0
  37. data/lib/friendly/cukes/framework/coverage/rcov/object_repository-desktop-google_search_rb.html +230 -0
  38. data/lib/friendly/cukes/framework/coverage/rcov/object_repository-mobile-mobile_google_search_rb.html +230 -0
  39. data/lib/friendly/cukes/framework/coverage/rcov/step_definitions-desktop-gem_search_rb.html +188 -0
  40. data/lib/friendly/cukes/framework/coverage/rcov/step_definitions-desktop-google_search_steps_rb.html +167 -0
  41. data/lib/friendly/cukes/framework/coverage/rcov/step_definitions-mobile-mobile_google_search_steps_rb.html +167 -0
  42. data/lib/friendly/cukes/framework/coverage/rcov/support-browser_settings_rb.html +851 -0
  43. data/lib/friendly/cukes/framework/coverage/rcov/support-env_rb.html +242 -0
  44. data/lib/friendly/cukes/framework/coverage/rcov/support-hooks_rb.html +878 -0
  45. data/lib/friendly/cukes/framework/coverage/rcov/support-html_formatter_rb.html +230 -0
  46. data/lib/friendly/cukes/framework/features/desktop/google_search/google_search.feature +19 -0
  47. data/lib/friendly/cukes/framework/features/desktop/rubygems_search/gem_name_tc_04.yml +2 -0
  48. data/lib/friendly/cukes/framework/features/desktop/rubygems_search/gem_search.feature +37 -0
  49. data/lib/friendly/cukes/framework/features/desktop/test_data/gem_name.yml +2 -0
  50. data/lib/friendly/cukes/framework/features/mobile/google_search/mobile_google_search.feature +19 -0
  51. data/lib/friendly/cukes/framework/library/app_init/app_init.rb +13 -0
  52. data/lib/friendly/cukes/framework/library/app_utils/data_file_names.rb +2 -0
  53. data/lib/friendly/cukes/framework/library/app_utils/page_utils.rb +157 -0
  54. data/lib/friendly/cukes/framework/library/generic/app_logo_1.png +0 -0
  55. data/lib/friendly/cukes/framework/library/generic/create_log.rb +154 -0
  56. data/lib/friendly/cukes/framework/library/generic/custom_html_report.rb +852 -0
  57. data/lib/friendly/cukes/framework/library/generic/datetime_library.rb +79 -0
  58. data/lib/friendly/cukes/framework/library/generic/file_library.rb +311 -0
  59. data/lib/friendly/cukes/framework/library/generic/performance_report.rb +518 -0
  60. data/lib/friendly/cukes/framework/library/generic/read_from_yml.rb +294 -0
  61. data/lib/friendly/cukes/framework/object_repository/desktop/desktop_web_object_repo.rb +50 -0
  62. data/lib/friendly/cukes/framework/object_repository/mobile/mobile_web_object_repo.rb +22 -0
  63. data/lib/friendly/cukes/framework/page_objects/desktop/gem_search.rb +213 -0
  64. data/lib/friendly/cukes/framework/page_objects/desktop/google_search.rb +53 -0
  65. data/lib/friendly/cukes/framework/page_objects/mobile/mobile_google_search.rb +53 -0
  66. data/lib/friendly/cukes/framework/step_definitions/desktop/gem_search.rb +43 -0
  67. data/lib/friendly/cukes/framework/step_definitions/desktop/google_search_steps.rb +36 -0
  68. data/lib/friendly/cukes/framework/step_definitions/mobile/mobile_google_search_steps.rb +36 -0
  69. data/lib/friendly/cukes/framework/support/browser_settings.rb +264 -0
  70. data/lib/friendly/cukes/framework/support/env.rb +65 -0
  71. data/lib/friendly/cukes/framework/support/hooks.rb +274 -0
  72. data/lib/friendly/cukes/framework/support/html_formatter.rb +57 -0
  73. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_33/app_env.log +15 -0
  74. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_33/custom_report/detailed_report/app_logo_1.png +0 -0
  75. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_33/custom_report/detailed_report/desktop_gem_search.html +647 -0
  76. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_33/custom_report/detailed_report/desktop_google_search.html +590 -0
  77. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_33/custom_report/report_home.html +593 -0
  78. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_33/desktop_rubygems_search.log +84 -0
  79. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_33/report_21_05_2015-11_04_54.html +472 -0
  80. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_33/report_21_05_2015-11_04_54.json +299 -0
  81. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_37/app_env.log +15 -0
  82. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_37/desktop_google_search.log +22 -0
  83. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_37/report_21_05_2015-11_03_49.html +472 -0
  84. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-11_03_37/report_21_05_2015-11_03_49.json +155 -0
  85. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-17_28_10/app_env.log +15 -0
  86. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-17_28_10/mobile_google_search.log +22 -0
  87. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-17_28_10/report_21_05_2015-17_29_26.html +472 -0
  88. data/lib/friendly/cukes/framework/test_result/test_report_21_05_2015-17_28_10/report_21_05_2015-17_29_26.json +143 -0
  89. data/lib/friendly/cukes/version.rb +61 -0
  90. metadata +309 -0
@@ -0,0 +1,521 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2
+ <html lang='en' xml:lang='en' xmlns='http://www.w3.org/1999/xhtml'>
3
+ <head>
4
+ <title>library/generic/create_log.rb</title>
5
+ <link href="./assets/0.2.3/screen.css" media="all" rel="stylesheet" type="text/css" />
6
+ <link href="./assets/0.2.3/print.css" media="print" rel="stylesheet" type="text/css" />
7
+ <meta http-equiv="Content-type" content="text/html;charset=UTF-8" />
8
+ <script type="text/javascript" src="./assets/0.2.3/rcov.js"></script>
9
+ </head>
10
+ <body>
11
+ <h1>Cukes C0 Coverage Information - Simploco - RCov</h1>
12
+ <h2>library/generic/create_log.rb</h2>
13
+
14
+ <div class="report_table_wrapper">
15
+ <table class='report' id='report_table'>
16
+ <thead>
17
+ <tr>
18
+ <th class="left_align">Name</th>
19
+ <th class="right_align">Total Lines</th>
20
+ <th class="right_align">Lines of Code</th>
21
+ <th class="left_align">Total Coverage</th>
22
+ <th class="left_align">Code Coverage</th>
23
+ </tr>
24
+ </thead>
25
+ <tbody>
26
+ <tr>
27
+ <td class="left_align"><a href="library-generic-create_log_rb.html">library/generic/create_log.rb</a></td>
28
+ <td class='right_align'><tt>154</tt></td>
29
+ <td class='right_align'><tt>51</tt></td>
30
+ <td class="left_align"><div class="percent_graph_legend"><tt class=''>94.16%</tt></div>
31
+ <div class="percent_graph">
32
+ <div class="covered" style="width:94px"></div>
33
+ <div class="uncovered" style="width:6px"></div>
34
+ </div></td>
35
+ <td class="left_align"><div class="percent_graph_legend"><tt class=''>82.35%</tt></div>
36
+ <div class="percent_graph">
37
+ <div class="covered" style="width:82px"></div>
38
+ <div class="uncovered" style="width:18px"></div>
39
+ </div></td>
40
+ </tr>
41
+ </tbody>
42
+ </table>
43
+ </div>
44
+
45
+ <h3>Key</h3>
46
+
47
+ <div class="key"><pre><span class='marked'>Code reported as executed by Ruby looks like this...</span><span class='marked1'>and this: this line is also marked as covered.</span><span class='inferred'>Lines considered as run by rcov, but not reported by Ruby, look like this,</span><span class='inferred1'>and this: these lines were inferred by rcov (using simple heuristics).</span><span class='uncovered'>Finally, here's a line marked as not executed.</span></pre></div>
48
+
49
+ <h3>Coverage Details</h3>
50
+
51
+ <table class="details">
52
+ <tbody>
53
+ <tr class="inferred">
54
+ <td><pre><a name="line2">2</a> =begin</pre></td>
55
+ </tr>
56
+ <tr class="inferred">
57
+ <td><pre><a name="line3">3</a> *Name : CreateLog</pre></td>
58
+ </tr>
59
+ <tr class="inferred">
60
+ <td><pre><a name="line4">4</a> *Description : class that defines custom logger methods</pre></td>
61
+ </tr>
62
+ <tr class="inferred">
63
+ <td><pre><a name="line5">5</a> *Author : Chandra sekaran</pre></td>
64
+ </tr>
65
+ <tr class="inferred">
66
+ <td><pre><a name="line6">6</a> *Creation Date : 23/08/2014</pre></td>
67
+ </tr>
68
+ <tr class="inferred">
69
+ <td><pre><a name="line7">7</a> *Updation Date :</pre></td>
70
+ </tr>
71
+ <tr class="inferred">
72
+ <td><pre><a name="line8">8</a> =end</pre></td>
73
+ </tr>
74
+ <tr class="inferred">
75
+ <td><pre><a name="line9">9</a> </pre></td>
76
+ </tr>
77
+ <tr class="marked">
78
+ <td><pre><a name="line10">10</a> module CUKES</pre></td>
79
+ </tr>
80
+ <tr class="marked">
81
+ <td><pre><a name="line11">11</a> class CreateLog</pre></td>
82
+ </tr>
83
+ <tr class="marked">
84
+ <td><pre><a name="line12">12</a> include FileLibrary # module that define methods all file related manipulations</pre></td>
85
+ </tr>
86
+ <tr class="marked">
87
+ <td><pre><a name="line13">13</a> include DateTimeLibrary # module that define methods for all datetime related manipulations</pre></td>
88
+ </tr>
89
+ <tr class="inferred">
90
+ <td><pre><a name="line14">14</a> </pre></td>
91
+ </tr>
92
+ <tr class="inferred">
93
+ <td><pre><a name="line15">15</a> # Description : initializes the Logger class and creates a new log file</pre></td>
94
+ </tr>
95
+ <tr class="inferred">
96
+ <td><pre><a name="line16">16</a> # Author : Chandra sekaran</pre></td>
97
+ </tr>
98
+ <tr class="inferred">
99
+ <td><pre><a name="line17">17</a> # Arguments :</pre></td>
100
+ </tr>
101
+ <tr class="inferred">
102
+ <td><pre><a name="line18">18</a> # str_logfile_name: name of the log file to be created</pre></td>
103
+ </tr>
104
+ <tr class="inferred">
105
+ <td><pre><a name="line19">19</a> #</pre></td>
106
+ </tr>
107
+ <tr class="marked">
108
+ <td><pre><a name="line20">20</a> def initialize(str_logfile_name = &quot;log_&quot;)</pre></td>
109
+ </tr>
110
+ <tr class="marked">
111
+ <td><pre><a name="line21">21</a> begin</pre></td>
112
+ </tr>
113
+ <tr class="marked">
114
+ <td><pre><a name="line22">22</a> date_time_format = DATETIME_FORMAT || &quot;%d_%m_%Y-%H_%M_%S&quot;</pre></td>
115
+ </tr>
116
+ <tr class="inferred">
117
+ <td><pre><a name="line23">23</a> rescue Exception =&gt; ex</pre></td>
118
+ </tr>
119
+ <tr class="marked">
120
+ <td><pre><a name="line24">24</a> date_time_format = &quot;%d_%m_%Y-%H_%M_%S&quot; # when DATETIME_FORMAT is not defined</pre></td>
121
+ </tr>
122
+ <tr class="inferred">
123
+ <td><pre><a name="line25">25</a> end</pre></td>
124
+ </tr>
125
+ <tr class="inferred">
126
+ <td><pre><a name="line26">26</a> </pre></td>
127
+ </tr>
128
+ <tr class="marked">
129
+ <td><pre><a name="line27">27</a> begin</pre></td>
130
+ </tr>
131
+ <tr class="marked">
132
+ <td><pre><a name="line28">28</a> level = LOGGER_LEVEL || &quot;DEBUG&quot;</pre></td>
133
+ </tr>
134
+ <tr class="inferred">
135
+ <td><pre><a name="line29">29</a> rescue Exception =&gt; ex</pre></td>
136
+ </tr>
137
+ <tr class="marked">
138
+ <td><pre><a name="line30">30</a> level = &quot;DEBUG&quot; # when LOGGER_LEVEL is not defined</pre></td>
139
+ </tr>
140
+ <tr class="inferred">
141
+ <td><pre><a name="line31">31</a> end</pre></td>
142
+ </tr>
143
+ <tr class="inferred">
144
+ <td><pre><a name="line32">32</a> </pre></td>
145
+ </tr>
146
+ <tr class="marked">
147
+ <td><pre><a name="line33">33</a> begin</pre></td>
148
+ </tr>
149
+ <tr class="marked">
150
+ <td><pre><a name="line34">34</a> @str_logdir_name = $current_log_dir || &quot;./test_result/test_report_#{Time.now.strftime(date_time_format)}&quot; # this line is enough, ex handlng not need</pre></td>
151
+ </tr>
152
+ <tr class="inferred">
153
+ <td><pre><a name="line35">35</a> rescue Exception =&gt; ex</pre></td>
154
+ </tr>
155
+ <tr class="uncovered">
156
+ <td><pre><a name="line36">36</a> @str_logdir_name = &quot;./test_result/test_report_#{Time.now.strftime(date_time_format)}&quot;</pre></td>
157
+ </tr>
158
+ <tr class="inferred">
159
+ <td><pre><a name="line37">37</a> end</pre></td>
160
+ </tr>
161
+ <tr class="inferred">
162
+ <td><pre><a name="line38">38</a> </pre></td>
163
+ </tr>
164
+ <tr class="marked">
165
+ <td><pre><a name="line39">39</a> create_directory(@str_logdir_name) # creates a new directory</pre></td>
166
+ </tr>
167
+ <tr class="marked">
168
+ <td><pre><a name="line40">40</a> @log_file = &quot;#{@str_logdir_name}/#{str_logfile_name}.log&quot;</pre></td>
169
+ </tr>
170
+ <tr class="marked">
171
+ <td><pre><a name="line41">41</a> @log = Logger.new(@log_file) # creates a new log file</pre></td>
172
+ </tr>
173
+ <tr class="marked">
174
+ <td><pre><a name="line42">42</a> set_level(level) # sets the Logger::Level</pre></td>
175
+ </tr>
176
+ <tr class="marked">
177
+ <td><pre><a name="line43">43</a> @log.datetime_format = date_time_format # sets the datetime format</pre></td>
178
+ </tr>
179
+ <tr class="marked">
180
+ <td><pre><a name="line44">44</a> @log.formatter = lambda do |severity, datetime, progname, message|</pre></td>
181
+ </tr>
182
+ <tr class="marked">
183
+ <td><pre><a name="line45">45</a> &quot;[#{Time.now.strftime(date_time_format)}] #{severity}: #{message}\n&quot; # customize the log content</pre></td>
184
+ </tr>
185
+ <tr class="inferred">
186
+ <td><pre><a name="line46">46</a> end</pre></td>
187
+ </tr>
188
+ <tr class="inferred">
189
+ <td><pre><a name="line47">47</a> end</pre></td>
190
+ </tr>
191
+ <tr class="inferred">
192
+ <td><pre><a name="line48">48</a> </pre></td>
193
+ </tr>
194
+ <tr class="inferred">
195
+ <td><pre><a name="line49">49</a> # Description : logs a DEBUG message</pre></td>
196
+ </tr>
197
+ <tr class="inferred">
198
+ <td><pre><a name="line50">50</a> # Author : Chandra sekaran</pre></td>
199
+ </tr>
200
+ <tr class="inferred">
201
+ <td><pre><a name="line51">51</a> # Arguments :</pre></td>
202
+ </tr>
203
+ <tr class="inferred">
204
+ <td><pre><a name="line52">52</a> # message : string message to be logged</pre></td>
205
+ </tr>
206
+ <tr class="inferred">
207
+ <td><pre><a name="line53">53</a> #</pre></td>
208
+ </tr>
209
+ <tr class="marked">
210
+ <td><pre><a name="line54">54</a> def debug(message)</pre></td>
211
+ </tr>
212
+ <tr class="uncovered">
213
+ <td><pre><a name="line55">55</a> @log.debug(message)</pre></td>
214
+ </tr>
215
+ <tr class="inferred">
216
+ <td><pre><a name="line56">56</a> end</pre></td>
217
+ </tr>
218
+ <tr class="inferred">
219
+ <td><pre><a name="line57">57</a> </pre></td>
220
+ </tr>
221
+ <tr class="inferred">
222
+ <td><pre><a name="line58">58</a> # Description : logs an INFO message</pre></td>
223
+ </tr>
224
+ <tr class="inferred">
225
+ <td><pre><a name="line59">59</a> # Author : Chandra sekaran</pre></td>
226
+ </tr>
227
+ <tr class="inferred">
228
+ <td><pre><a name="line60">60</a> # Arguments :</pre></td>
229
+ </tr>
230
+ <tr class="inferred">
231
+ <td><pre><a name="line61">61</a> # message : string message to be logged</pre></td>
232
+ </tr>
233
+ <tr class="inferred">
234
+ <td><pre><a name="line62">62</a> #</pre></td>
235
+ </tr>
236
+ <tr class="marked">
237
+ <td><pre><a name="line63">63</a> def info(message)</pre></td>
238
+ </tr>
239
+ <tr class="marked">
240
+ <td><pre><a name="line64">64</a> @log.info(message)</pre></td>
241
+ </tr>
242
+ <tr class="inferred">
243
+ <td><pre><a name="line65">65</a> end</pre></td>
244
+ </tr>
245
+ <tr class="inferred">
246
+ <td><pre><a name="line66">66</a> </pre></td>
247
+ </tr>
248
+ <tr class="inferred">
249
+ <td><pre><a name="line67">67</a> # Description : logs a WARN message</pre></td>
250
+ </tr>
251
+ <tr class="inferred">
252
+ <td><pre><a name="line68">68</a> # Author : Chandra sekaran</pre></td>
253
+ </tr>
254
+ <tr class="inferred">
255
+ <td><pre><a name="line69">69</a> # Arguments :</pre></td>
256
+ </tr>
257
+ <tr class="inferred">
258
+ <td><pre><a name="line70">70</a> # message : string message to be logged</pre></td>
259
+ </tr>
260
+ <tr class="inferred">
261
+ <td><pre><a name="line71">71</a> #</pre></td>
262
+ </tr>
263
+ <tr class="marked">
264
+ <td><pre><a name="line72">72</a> def warn(message)</pre></td>
265
+ </tr>
266
+ <tr class="uncovered">
267
+ <td><pre><a name="line73">73</a> @log.warn(message)</pre></td>
268
+ </tr>
269
+ <tr class="inferred">
270
+ <td><pre><a name="line74">74</a> end</pre></td>
271
+ </tr>
272
+ <tr class="inferred">
273
+ <td><pre><a name="line75">75</a> </pre></td>
274
+ </tr>
275
+ <tr class="inferred">
276
+ <td><pre><a name="line76">76</a> # Description : logs an ERROR message</pre></td>
277
+ </tr>
278
+ <tr class="inferred">
279
+ <td><pre><a name="line77">77</a> # Author : Chandra sekaran</pre></td>
280
+ </tr>
281
+ <tr class="inferred">
282
+ <td><pre><a name="line78">78</a> # Arguments :</pre></td>
283
+ </tr>
284
+ <tr class="inferred">
285
+ <td><pre><a name="line79">79</a> # message : string message to be logged</pre></td>
286
+ </tr>
287
+ <tr class="inferred">
288
+ <td><pre><a name="line80">80</a> #</pre></td>
289
+ </tr>
290
+ <tr class="marked">
291
+ <td><pre><a name="line81">81</a> def error(message)</pre></td>
292
+ </tr>
293
+ <tr class="uncovered">
294
+ <td><pre><a name="line82">82</a> @log.error(message)</pre></td>
295
+ </tr>
296
+ <tr class="inferred">
297
+ <td><pre><a name="line83">83</a> #$world.puts(message) if !$world.nil?</pre></td>
298
+ </tr>
299
+ <tr class="inferred">
300
+ <td><pre><a name="line84">84</a> #exit #raise #&quot;EXCEPTION RAISED&quot;#Cucumber.wants_to_quit = true # exit(1)</pre></td>
301
+ </tr>
302
+ <tr class="inferred">
303
+ <td><pre><a name="line85">85</a> end</pre></td>
304
+ </tr>
305
+ <tr class="inferred">
306
+ <td><pre><a name="line86">86</a> </pre></td>
307
+ </tr>
308
+ <tr class="inferred">
309
+ <td><pre><a name="line87">87</a> # Description : logs a success message</pre></td>
310
+ </tr>
311
+ <tr class="inferred">
312
+ <td><pre><a name="line88">88</a> # Author : Chandra sekaran</pre></td>
313
+ </tr>
314
+ <tr class="inferred">
315
+ <td><pre><a name="line89">89</a> # Arguments :</pre></td>
316
+ </tr>
317
+ <tr class="inferred">
318
+ <td><pre><a name="line90">90</a> # message : string message to be logged</pre></td>
319
+ </tr>
320
+ <tr class="inferred">
321
+ <td><pre><a name="line91">91</a> #</pre></td>
322
+ </tr>
323
+ <tr class="marked">
324
+ <td><pre><a name="line92">92</a> def success(message)</pre></td>
325
+ </tr>
326
+ <tr class="marked">
327
+ <td><pre><a name="line93">93</a> info(message)</pre></td>
328
+ </tr>
329
+ <tr class="marked">
330
+ <td><pre><a name="line94">94</a> $world.puts(message) if !$world.nil?</pre></td>
331
+ </tr>
332
+ <tr class="inferred">
333
+ <td><pre><a name="line95">95</a> end</pre></td>
334
+ </tr>
335
+ <tr class="inferred">
336
+ <td><pre><a name="line96">96</a> </pre></td>
337
+ </tr>
338
+ <tr class="inferred">
339
+ <td><pre><a name="line97">97</a> # Description : logs a FATAL message</pre></td>
340
+ </tr>
341
+ <tr class="inferred">
342
+ <td><pre><a name="line98">98</a> # Author : Chandra sekaran</pre></td>
343
+ </tr>
344
+ <tr class="inferred">
345
+ <td><pre><a name="line99">99</a> # Arguments :</pre></td>
346
+ </tr>
347
+ <tr class="inferred">
348
+ <td><pre><a name="line100">100</a> # message : string message to be logged</pre></td>
349
+ </tr>
350
+ <tr class="inferred">
351
+ <td><pre><a name="line101">101</a> #</pre></td>
352
+ </tr>
353
+ <tr class="marked">
354
+ <td><pre><a name="line102">102</a> def fatal(message)</pre></td>
355
+ </tr>
356
+ <tr class="uncovered">
357
+ <td><pre><a name="line103">103</a> @log.fatal(message)</pre></td>
358
+ </tr>
359
+ <tr class="inferred">
360
+ <td><pre><a name="line104">104</a> end</pre></td>
361
+ </tr>
362
+ <tr class="inferred">
363
+ <td><pre><a name="line105">105</a> </pre></td>
364
+ </tr>
365
+ <tr class="inferred">
366
+ <td><pre><a name="line106">106</a> # Description : sets the logger level</pre></td>
367
+ </tr>
368
+ <tr class="inferred">
369
+ <td><pre><a name="line107">107</a> # Author : Chandra sekaran</pre></td>
370
+ </tr>
371
+ <tr class="inferred">
372
+ <td><pre><a name="line108">108</a> # Arguments :</pre></td>
373
+ </tr>
374
+ <tr class="inferred">
375
+ <td><pre><a name="line109">109</a> # level : logger level string</pre></td>
376
+ </tr>
377
+ <tr class="inferred">
378
+ <td><pre><a name="line110">110</a> #</pre></td>
379
+ </tr>
380
+ <tr class="marked">
381
+ <td><pre><a name="line111">111</a> def set_level(level)</pre></td>
382
+ </tr>
383
+ <tr class="marked">
384
+ <td><pre><a name="line112">112</a> case level.upcase</pre></td>
385
+ </tr>
386
+ <tr class="inferred">
387
+ <td><pre><a name="line113">113</a> when &quot;DEBUG&quot;</pre></td>
388
+ </tr>
389
+ <tr class="marked">
390
+ <td><pre><a name="line114">114</a> @log.level = Logger::DEBUG</pre></td>
391
+ </tr>
392
+ <tr class="inferred">
393
+ <td><pre><a name="line115">115</a> when &quot;INFO&quot;</pre></td>
394
+ </tr>
395
+ <tr class="uncovered">
396
+ <td><pre><a name="line116">116</a> @log.level = Logger::INFO</pre></td>
397
+ </tr>
398
+ <tr class="inferred">
399
+ <td><pre><a name="line117">117</a> when &quot;WARN&quot;</pre></td>
400
+ </tr>
401
+ <tr class="uncovered">
402
+ <td><pre><a name="line118">118</a> @log.level = Logger::WARN</pre></td>
403
+ </tr>
404
+ <tr class="inferred">
405
+ <td><pre><a name="line119">119</a> when &quot;ERROR&quot;</pre></td>
406
+ </tr>
407
+ <tr class="uncovered">
408
+ <td><pre><a name="line120">120</a> @log.level = Logger::ERROR</pre></td>
409
+ </tr>
410
+ <tr class="inferred">
411
+ <td><pre><a name="line121">121</a> when &quot;FATAL&quot;</pre></td>
412
+ </tr>
413
+ <tr class="uncovered">
414
+ <td><pre><a name="line122">122</a> @log.level = Logger::FATAL</pre></td>
415
+ </tr>
416
+ <tr class="inferred">
417
+ <td><pre><a name="line123">123</a> end</pre></td>
418
+ </tr>
419
+ <tr class="inferred">
420
+ <td><pre><a name="line124">124</a> end</pre></td>
421
+ </tr>
422
+ <tr class="inferred">
423
+ <td><pre><a name="line125">125</a> </pre></td>
424
+ </tr>
425
+ <tr class="inferred">
426
+ <td><pre><a name="line126">126</a> # Description : creates a new directory under the given path (newly added to override the method in file_library.rb)</pre></td>
427
+ </tr>
428
+ <tr class="inferred">
429
+ <td><pre><a name="line127">127</a> # Author : Chandra sekaran</pre></td>
430
+ </tr>
431
+ <tr class="inferred">
432
+ <td><pre><a name="line128">128</a> # Arguments :</pre></td>
433
+ </tr>
434
+ <tr class="inferred">
435
+ <td><pre><a name="line129">129</a> # str_directory_path : relative path of the directory to be created</pre></td>
436
+ </tr>
437
+ <tr class="inferred">
438
+ <td><pre><a name="line130">130</a> #</pre></td>
439
+ </tr>
440
+ <tr class="marked">
441
+ <td><pre><a name="line131">131</a> def create_directory(str_directory_path)</pre></td>
442
+ </tr>
443
+ <tr class="marked">
444
+ <td><pre><a name="line132">132</a> unless File.directory?(str_directory_path)</pre></td>
445
+ </tr>
446
+ <tr class="marked">
447
+ <td><pre><a name="line133">133</a> FileUtils.mkdir_p(str_directory_path)</pre></td>
448
+ </tr>
449
+ <tr class="marked">
450
+ <td><pre><a name="line134">134</a> puts &quot;New directory created under : #{str_directory_path}&quot;</pre></td>
451
+ </tr>
452
+ <tr class="inferred">
453
+ <td><pre><a name="line135">135</a> end</pre></td>
454
+ </tr>
455
+ <tr class="inferred">
456
+ <td><pre><a name="line136">136</a> end</pre></td>
457
+ </tr>
458
+ <tr class="inferred">
459
+ <td><pre><a name="line137">137</a> </pre></td>
460
+ </tr>
461
+ <tr class="inferred">
462
+ <td><pre><a name="line138">138</a> # Description : returns the relative path of currently created directory</pre></td>
463
+ </tr>
464
+ <tr class="inferred">
465
+ <td><pre><a name="line139">139</a> # Author : Chandra sekaran</pre></td>
466
+ </tr>
467
+ <tr class="inferred">
468
+ <td><pre><a name="line140">140</a> #</pre></td>
469
+ </tr>
470
+ <tr class="marked">
471
+ <td><pre><a name="line141">141</a> def get_current_log_dir</pre></td>
472
+ </tr>
473
+ <tr class="marked">
474
+ <td><pre><a name="line142">142</a> @str_logdir_name</pre></td>
475
+ </tr>
476
+ <tr class="inferred">
477
+ <td><pre><a name="line143">143</a> end</pre></td>
478
+ </tr>
479
+ <tr class="inferred">
480
+ <td><pre><a name="line144">144</a> </pre></td>
481
+ </tr>
482
+ <tr class="inferred">
483
+ <td><pre><a name="line145">145</a> # Description : returns the relative path of currently created file (logfile)</pre></td>
484
+ </tr>
485
+ <tr class="inferred">
486
+ <td><pre><a name="line146">146</a> # Author : Chandra sekaran</pre></td>
487
+ </tr>
488
+ <tr class="inferred">
489
+ <td><pre><a name="line147">147</a> #</pre></td>
490
+ </tr>
491
+ <tr class="marked">
492
+ <td><pre><a name="line148">148</a> def get_current_log_file</pre></td>
493
+ </tr>
494
+ <tr class="marked">
495
+ <td><pre><a name="line149">149</a> @log_file</pre></td>
496
+ </tr>
497
+ <tr class="inferred">
498
+ <td><pre><a name="line150">150</a> end</pre></td>
499
+ </tr>
500
+ <tr class="inferred">
501
+ <td><pre><a name="line151">151</a> </pre></td>
502
+ </tr>
503
+ <tr class="marked">
504
+ <td><pre><a name="line152">152</a> private</pre></td>
505
+ </tr>
506
+ <tr class="marked">
507
+ <td><pre><a name="line153">153</a> attr_reader :log</pre></td>
508
+ </tr>
509
+ <tr class="inferred">
510
+ <td><pre><a name="line154">154</a> end</pre></td>
511
+ </tr>
512
+ <tr class="inferred">
513
+ <td><pre><a name="line155">155</a> end</pre></td>
514
+ </tr>
515
+ </tbody>
516
+ </table>
517
+
518
+ <p>Generated on 2015-05-08 10:40:30 +0530 with <a href="https://github.com/fguillen/simplecov-rcov">SimpleCov-RCov 0.2.3</a></p>
519
+
520
+ </body>
521
+ </html>