tapestry 0.3.0 → 0.4.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 97071b0620b77a712b23f55c7cc963490c44a1f2
4
- data.tar.gz: 4638ffbd0eca52923e7c317daecf832fd8c9d307
3
+ metadata.gz: 2e9967d3436adf2507d7327d7729e4eea409ea24
4
+ data.tar.gz: 4ccd83157418ddc83803e97d50a06e0822d35491
5
5
  SHA512:
6
- metadata.gz: 96a87aeb47a636fc773324ad9ce9dd021819d3117a18afb1ee46c8ef5aaebf0954b493dc3e452b24046e8f30964694e765bfdfb67f17eeec9c6f7f3acd1f55f6
7
- data.tar.gz: ea2fb3473c7ba52f15126039d44adf2670c610ca5f21be1a316507b134eb707ba059273cef2ad71562cca7479b05b6579ae82e62fcbb1301cb9205acbce0d53d
6
+ metadata.gz: 402038675699822de8ad9f6ddadbce05ec4b57b4ee454b601fc266dfe6fff6ea001e7b887c42823f797feddfedeaeeb8b756f2ecba493f54e23960c056616e37
7
+ data.tar.gz: ae9d952c57f744812d06e079a5ef176002856ef91fdf5f4b98ab3aaca2932ab1a20616d1d0b6ecbe0c96691f49ca7373af96d5bd981cd7003f8861a094fcf49e
data/.hound.yml CHANGED
@@ -30,15 +30,15 @@ Style/SignalException:
30
30
  Enabled: false
31
31
 
32
32
  # This never works for validations.
33
- Style/AlignHash:
33
+ Layout/AlignHash:
34
34
  EnforcedLastArgumentHashStyle: ignore_implicit
35
35
 
36
36
  # Align multi-line params with previous line.
37
- Style/AlignParameters:
37
+ Layout/AlignParameters:
38
38
  EnforcedStyle: with_fixed_indentation
39
39
 
40
40
  # Indent `when` clause one step from `case`.
41
- Style/CaseIndentation:
41
+ Layout/CaseIndentation:
42
42
  IndentOneStep: true
43
43
 
44
44
  # Don't force bad var names for reduce/inject loops.
@@ -46,7 +46,7 @@ Style/SingleLineBlockParams:
46
46
  Enabled: false
47
47
 
48
48
  # For method chains, keep the dot with the method name.
49
- Style/DotPosition:
49
+ Layout/DotPosition:
50
50
  EnforcedStyle: leading
51
51
 
52
52
  # Stop nesting so hard.
@@ -57,12 +57,16 @@ Metrics/BlockNesting:
57
57
  Metrics/MethodLength:
58
58
  Max: 15
59
59
 
60
+ # Encourage short (as possible) modules.
61
+ Metrics/ModuleLength:
62
+ Max: 105
63
+
60
64
  # Encourage fewer parameters.
61
65
  Metrics/ParameterLists:
62
66
  Max: 4
63
67
 
64
68
  # Allow methods with has_ for predicates.
65
- Style/PredicateName:
69
+ Naming/PredicateName:
66
70
  NameWhitelist:
67
71
  - has_correct_url?
68
72
  - has_correct_title?
@@ -14,7 +14,7 @@ module Tapestry
14
14
  end
15
15
 
16
16
  def elements
17
- @elements = Watir::Container.instance_methods unless @elements
17
+ @elements ||= Watir::Container.instance_methods unless @elements
18
18
  end
19
19
 
20
20
  module Element
@@ -119,6 +119,12 @@ module Tapestry
119
119
 
120
120
  alias refresh_page refresh
121
121
 
122
+ # This method provides a means to maximize the browser window. This
123
+ # is done by getting the screen width and height via JavaScript calls.
124
+ def maximize
125
+ browser.window.resize_to(screen_width, screen_height)
126
+ end
127
+
122
128
  # This method provides a call to the browser window to resize that
123
129
  # window to the specified width and height values.
124
130
  def resize(width, height)
@@ -198,6 +204,22 @@ module Tapestry
198
204
  end
199
205
 
200
206
  alias remove_cookies clear_cookies
207
+
208
+ def watir_api
209
+ Tapestry.browser.methods - Object.public_methods
210
+ end
211
+
212
+ def selenium_api
213
+ Tapestry.browser.driver.methods - Object.public_methods
214
+ end
215
+
216
+ def api
217
+ methods - Object.public_methods
218
+ end
219
+
220
+ def definition_api
221
+ public_methods(false) - Object.public_methods
222
+ end
201
223
  end
202
224
  end
203
225
  end
@@ -1,7 +1,7 @@
1
1
  module Tapestry
2
2
  module_function
3
3
 
4
- VERSION = "0.3.0".freeze
4
+ VERSION = "0.4.0".freeze
5
5
 
6
6
  def version
7
7
  """
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tapestry
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeff Nyman
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-08-02 00:00:00.000000000 Z
11
+ date: 2017-11-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -151,7 +151,7 @@ licenses:
151
151
  - MIT
152
152
  metadata: {}
153
153
  post_install_message: "\n(::) (::) (::) (::) (::) (::) (::) (::) (::) (::) (::) (::)\n
154
- \ Tapestry 0.3.0 has been installed.\n(::) (::) (::) (::) (::) (::) (::) (::) (::)
154
+ \ Tapestry 0.4.0 has been installed.\n(::) (::) (::) (::) (::) (::) (::) (::) (::)
155
155
  (::) (::) (::)\n "
156
156
  rdoc_options: []
157
157
  require_paths: