Ifd_Automation 0.1.4 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/Ifd_Automation/email_steps.rb +34 -34
- data/lib/Ifd_Automation/lib_schema_data_steps.rb +2 -2
- data/lib/Ifd_Automation/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 450b7abaab5c5afe5b513edf453af297a0e8d987
|
4
|
+
data.tar.gz: a5a47b0dc93f2bd3c027658e1a73515664fac457
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a8f2fe476bd8a9c0c2ff47f3d2cb7712d2a4fa213bef840ba213833c07996405dfdc2502854a20fdc2aefbad7a16bcb004a2df2ed2ee34f01a5ba50ce4fa81e
|
7
|
+
data.tar.gz: a347f743072190ce6bc43b75d3c0abf500498f56f265147b8ebf7bf0267bc92bf52ff1c45076d461d4e86178f1b9c68d7d542d9df071cfa7d47ba8c0524c9b34
|
@@ -55,37 +55,37 @@ Then /^I should receive the mail from "(.*)" with subject "(.*)" and Email conte
|
|
55
55
|
raise "WARNING: *** No new Email is found"
|
56
56
|
end
|
57
57
|
end
|
58
|
-
|
59
|
-
Then /^I send the email to "(.*)" with subject is "(.*)" and email body template in "(.*)" file and following conditions:$/ do |to_address, subject, file, data_table|
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
end
|
58
|
+
#
|
59
|
+
# Then /^I send the email to "(.*)" with subject is "(.*)" and email body template in "(.*)" file and following conditions:$/ do |to_address, subject, file, data_table|
|
60
|
+
# data_file = File.read($test_data_dir + file)
|
61
|
+
# filepath = ($test_data_dir + file)
|
62
|
+
# body_email = data_file.force_encoding('UTF-8').encode('UTF-16', :invalid => :replace, :replace => "'").encode('UTF-8')
|
63
|
+
# if File.exist?(filepath)
|
64
|
+
# raw_data = JSON.parse(JSON.generate(data_table))
|
65
|
+
# header = raw_data[0]
|
66
|
+
# value = raw_data[1]
|
67
|
+
# $test = String.new
|
68
|
+
# $i = 0
|
69
|
+
# body_email.each_line do |lines|
|
70
|
+
# header.zip(value).each do |headers, values|
|
71
|
+
# group1, group2, group3= lines.match(/(^.*)(:)(.*)/i).try(:captures)
|
72
|
+
# if headers == group1 && group1.size > 0
|
73
|
+
# $new_value = lines.gsub(group3, " #{values}")
|
74
|
+
# $test += "#{$new_value}"
|
75
|
+
# $i = 1
|
76
|
+
# break
|
77
|
+
# elsif headers == "taaknummer"
|
78
|
+
# $new_value = lines.gsub("[TASKID]", " #{values}")
|
79
|
+
# $test += "#{$new_value}"
|
80
|
+
# $i = 1
|
81
|
+
# else
|
82
|
+
# $i = 0
|
83
|
+
# end
|
84
|
+
# end
|
85
|
+
# if $i == 0
|
86
|
+
# $test += "#{lines}"
|
87
|
+
# end
|
88
|
+
# end
|
89
|
+
# IFD_Email.send_email(to_address, subject, $test)
|
90
|
+
# end
|
91
|
+
# end
|
@@ -58,8 +58,8 @@ Then /^I should ( not)? see data in table "([^\"]*)" on "([^\"]*)" schema in dat
|
|
58
58
|
end
|
59
59
|
# Step used to check if data exists in database or not with condition in file
|
60
60
|
Then /^I should ( not)? see data in schema "(.*)" database with SQL query in file "(.*)"$/ do |negative, schema, file|
|
61
|
-
sql = File.read($
|
62
|
-
filepath = ($
|
61
|
+
sql = File.read($sql_dir + file)
|
62
|
+
filepath = ($sql_dir + file)
|
63
63
|
if File.exist?(filepath)
|
64
64
|
begin
|
65
65
|
rs = DatabaseMethods.execute_select(schema, sql)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: Ifd_Automation
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Anh Pham
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-10-
|
11
|
+
date: 2015-10-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: cucumber
|