watir_robot 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.
data/CHANGELOG CHANGED
@@ -1,3 +1,5 @@
1
+ v0.1.5 Add keywrods to Element for sending keys (typing) into any element.
2
+
1
3
  v0.1.4 Add keywords to TextField module.
2
4
 
3
5
  v0.1.3. Include the new Area module which was coded in a previous version, but omitted from the KeywordLib class.
@@ -45,6 +45,26 @@ module WatirRobot
45
45
  def focus(loc)
46
46
  @browser.element(parse_location(loc)).focus
47
47
  end
48
+
49
+ #
50
+ # Type text into the given text field (alternate for "Type Text")
51
+ #
52
+ # @param [String] loc attribute/value pairs that match an HTML element
53
+ # @param [String] text the text to type into the field
54
+ #
55
+ def send_keys(loc, text)
56
+ @browser.element(parse_location(loc)).send_keys(text)
57
+ end
58
+
59
+ #
60
+ # Type text into the given text field (alternate for "Send Keys")
61
+ #
62
+ # @param [String] loc attribute/value pairs that match an HTML element
63
+ # @param [String] text the text to type into the field
64
+ #
65
+ def type_text(loc, text)
66
+ @browser.element(parse_location(loc)).send_keys(text)
67
+ end
48
68
 
49
69
  ### Conditions ###
50
70
 
data/watir_robot.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{watir_robot}
5
- s.version = "0.1.4"
5
+ s.version = "0.1.5"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Daniel Gregoire"]
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: watir_robot
3
3
  version: !ruby/object:Gem::Version
4
- hash: 19
4
+ hash: 17
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 4
10
- version: 0.1.4
9
+ - 5
10
+ version: 0.1.5
11
11
  platform: ruby
12
12
  authors:
13
13
  - Daniel Gregoire