appium_lib 10.2.0 → 10.3.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 +4 -4
- data/.rubocop.yml +1 -14
- data/.travis.yml +0 -2
- data/CHANGELOG.md +9 -0
- data/Gemfile +14 -0
- data/Rakefile +14 -0
- data/appium_lib.gemspec +2 -2
- data/docs/android_docs.md +261 -229
- data/docs/ios_docs.md +346 -282
- data/lib/appium_lib.rb +14 -0
- data/lib/appium_lib/android/android.rb +14 -0
- data/lib/appium_lib/android/common/command/command.rb +14 -0
- data/lib/appium_lib/android/common/helper.rb +14 -0
- data/lib/appium_lib/android/element/alert.rb +14 -0
- data/lib/appium_lib/android/element/button.rb +35 -18
- data/lib/appium_lib/android/element/generic.rb +14 -0
- data/lib/appium_lib/android/element/text.rb +29 -14
- data/lib/appium_lib/android/element/textfield.rb +30 -15
- data/lib/appium_lib/android/espresso.rb +14 -0
- data/lib/appium_lib/android/espresso/bridge.rb +14 -0
- data/lib/appium_lib/android/espresso/element.rb +14 -0
- data/lib/appium_lib/android/espresso/element/button.rb +26 -12
- data/lib/appium_lib/android/espresso/element/generic.rb +14 -0
- data/lib/appium_lib/android/espresso/helper.rb +14 -0
- data/lib/appium_lib/android/uiautomator2.rb +14 -0
- data/lib/appium_lib/android/uiautomator2/bridge.rb +14 -0
- data/lib/appium_lib/android/uiautomator2/element.rb +14 -0
- data/lib/appium_lib/android/uiautomator2/element/button.rb +14 -0
- data/lib/appium_lib/android/uiautomator2/helper.rb +14 -0
- data/lib/appium_lib/appium.rb +14 -0
- data/lib/appium_lib/common/command.rb +14 -0
- data/lib/appium_lib/common/command/ws_logcat.rb +14 -0
- data/lib/appium_lib/common/device.rb +14 -0
- data/lib/appium_lib/common/helper.rb +19 -5
- data/lib/appium_lib/common/http_client.rb +14 -0
- data/lib/appium_lib/common/log.rb +14 -0
- data/lib/appium_lib/common/multi_touch.rb +14 -0
- data/lib/appium_lib/common/touch_actions.rb +14 -0
- data/lib/appium_lib/common/wait.rb +14 -0
- data/lib/appium_lib/driver.rb +16 -2
- data/lib/appium_lib/ios/common/errors.rb +14 -0
- data/lib/appium_lib/ios/common/helper.rb +15 -1
- data/lib/appium_lib/ios/element/alert.rb +14 -0
- data/lib/appium_lib/ios/element/button.rb +26 -9
- data/lib/appium_lib/ios/element/generic.rb +14 -0
- data/lib/appium_lib/ios/element/text.rb +26 -9
- data/lib/appium_lib/ios/element/textfield.rb +25 -7
- data/lib/appium_lib/ios/ios.rb +14 -0
- data/lib/appium_lib/ios/xcuitest.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/bridge.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/command.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/command/certificate.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/command/gestures.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/command/get_context.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/command/multi_app_handler.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/command/pasteboard.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/command/source.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/element.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/element/button.rb +22 -8
- data/lib/appium_lib/ios/xcuitest/element/generic.rb +14 -0
- data/lib/appium_lib/ios/xcuitest/element/text.rb +22 -8
- data/lib/appium_lib/ios/xcuitest/element/textfield.rb +18 -4
- data/lib/appium_lib/ios/xcuitest/helper.rb +14 -0
- data/lib/appium_lib/sauce_labs.rb +14 -0
- data/lib/appium_lib/version.rb +16 -2
- data/release_notes.md +7 -0
- metadata +4 -4
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Android
|
3
17
|
module Espresso
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Android
|
3
17
|
module Espresso
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
require_relative 'uiautomator2/helper'
|
2
16
|
require_relative 'uiautomator2/element'
|
3
17
|
require_relative 'uiautomator2/bridge'
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
require_relative '../android'
|
2
16
|
|
3
17
|
module Appium
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
require_relative 'element/button'
|
2
16
|
|
3
17
|
module Appium
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Android
|
3
17
|
module Uiautomator2
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Android
|
3
17
|
module Uiautomator2
|
data/lib/appium_lib/appium.rb
CHANGED
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
require 'rubygems'
|
2
16
|
require 'selenium-webdriver'
|
3
17
|
require 'nokogiri'
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
require_relative 'command/ws_logcat'
|
2
16
|
|
3
17
|
module Appium
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Common
|
3
17
|
module Command
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Device
|
3
17
|
extend Forwardable
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
# Generic helper methods not specific to a particular tag name
|
2
16
|
module Appium
|
3
17
|
module Common
|
@@ -84,7 +98,7 @@ module Appium
|
|
84
98
|
@result
|
85
99
|
.sort_by { |_element, count| count }
|
86
100
|
.reverse
|
87
|
-
.
|
101
|
+
.reduce('') { |acc, element| "#{acc}#{element[1]}x #{element[0]}\n" }
|
88
102
|
.strip
|
89
103
|
end
|
90
104
|
end # class CountElements
|
@@ -160,7 +174,7 @@ module Appium
|
|
160
174
|
def lazy_load_strings
|
161
175
|
# app strings only works on local apps.
|
162
176
|
# on disk apps (ex: com.android.settings) will error
|
163
|
-
@
|
177
|
+
@lazy_load_strings ||= ignore { app_strings } || {}
|
164
178
|
end
|
165
179
|
|
166
180
|
# Search strings.xml's values for target.
|
@@ -168,7 +182,7 @@ module Appium
|
|
168
182
|
# @return [Array]
|
169
183
|
def xml_keys(target)
|
170
184
|
lazy_load_strings
|
171
|
-
@
|
185
|
+
@lazy_load_strings.select { |key, _value| key.downcase.include? target.downcase }
|
172
186
|
end
|
173
187
|
|
174
188
|
# Search strings.xml's keys for target.
|
@@ -176,7 +190,7 @@ module Appium
|
|
176
190
|
# @return [Array]
|
177
191
|
def xml_values(target)
|
178
192
|
lazy_load_strings
|
179
|
-
@
|
193
|
+
@lazy_load_strings.select { |_key, value| value.downcase.include? target.downcase }
|
180
194
|
end
|
181
195
|
|
182
196
|
# Resolve id in strings.xml and return the value.
|
@@ -184,7 +198,7 @@ module Appium
|
|
184
198
|
# @return [String]
|
185
199
|
def resolve_id(id)
|
186
200
|
lazy_load_strings
|
187
|
-
@
|
201
|
+
@lazy_load_strings[id]
|
188
202
|
end
|
189
203
|
|
190
204
|
# @private
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
require 'appium_lib_core'
|
2
16
|
require_relative '../version'
|
3
17
|
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Common
|
3
17
|
# @param [String|Hash] type You can get particular type's logs.
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
# MultiTouch actions allow for multiple touches to happen at the same time,
|
3
17
|
# for instance, to simulate multiple finger swipes.
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
# Perform a series of gestures, one after another. Gestures are chained
|
3
17
|
# together and only performed when `perform()` is called. Default is conducted by global driver.
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
require 'appium_lib_core'
|
2
16
|
|
3
17
|
module Appium
|
data/lib/appium_lib/driver.rb
CHANGED
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
# Load only Minitest is loaded
|
2
16
|
if defined?(Minitest::VERSION)
|
3
17
|
# Fix uninitialized constant Minitest (NameError)
|
@@ -176,7 +190,7 @@ module Appium
|
|
176
190
|
set_app_path(opts)
|
177
191
|
|
178
192
|
# enable debug patch
|
179
|
-
@appium_debug = appium_lib_opts.fetch :debug, !!defined?(Pry)
|
193
|
+
@appium_debug = appium_lib_opts.fetch :debug, !!defined?(Pry) # rubocop:disable Style/DoubleNegation
|
180
194
|
set_sauce_related_values(appium_lib_opts)
|
181
195
|
|
182
196
|
# Extend Common methods
|
@@ -214,7 +228,7 @@ module Appium
|
|
214
228
|
else # default and UiAutomator
|
215
229
|
::Appium::Android::Bridge.for(self)
|
216
230
|
end
|
217
|
-
when :ios
|
231
|
+
when :ios, :tvos
|
218
232
|
case automation_name
|
219
233
|
when :xcuitest
|
220
234
|
::Appium::Ios::Xcuitest::Bridge.for(self)
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Ios
|
3
17
|
class CommandError < RuntimeError
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Ios
|
3
17
|
# @private
|
@@ -7,7 +21,7 @@ module Appium
|
|
7
21
|
def start_element(type, attrs = [])
|
8
22
|
return if filter && !filter.eql?(type)
|
9
23
|
|
10
|
-
page = attrs.
|
24
|
+
page = attrs.each_with_object({}) do |hash, attr|
|
11
25
|
hash[attr[0]] = attr[1] if %w(name label value hint visible).include?(attr[0])
|
12
26
|
hash
|
13
27
|
end
|
@@ -1,3 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
1
15
|
module Appium
|
2
16
|
module Ios
|
3
17
|
# Accept the alert.
|