eyes_core 3.11.1 → 3.11.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/applitools/core/eyes_base.rb +22 -14
- data/lib/applitools/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: 0c31e4bb154d96ec0e95c99d06aee001aa38e9f8
|
4
|
+
data.tar.gz: 119a3a2555f1b731939eb4b7e4dfa015288c222e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 49b505655c65f25b6601cb8dae90819e421d11392be91b5d8de76f621a2bca878c589c59d4cbbcb925079828cbc67d7bc0fd4fb5e0ed98fa8d0d642fd181a868
|
7
|
+
data.tar.gz: 9f8a23713075f767289f5ed04b07aec9abfc9cf12aca5c854f2a0d10a5c4215897e38f7f704205b411188d8cc6086aada1a69d441dc02616a8d967db36bad1a4
|
@@ -74,13 +74,12 @@ module Applitools
|
|
74
74
|
self.match_level = Applitools::MATCH_LEVEL[:strict]
|
75
75
|
self.server_scale = 0
|
76
76
|
self.server_remainder = 0
|
77
|
+
end
|
77
78
|
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
remainder: server_remainder
|
83
|
-
}
|
79
|
+
def match_level=(value)
|
80
|
+
return @match_level = value if Applitools::MATCH_LEVEL.values.include?(value)
|
81
|
+
return @match_level = Applitools::MATCH_LEVEL[value.to_sym] if Applitools::MATCH_LEVEL.keys.include?(value.to_sym)
|
82
|
+
raise Applitools::EyesError, "Unknown match level #{value}"
|
84
83
|
end
|
85
84
|
|
86
85
|
# Sets default match_level which will be applied to any test, unless match_level is set for a test explicitly
|
@@ -92,13 +91,8 @@ module Applitools
|
|
92
91
|
# @option exact_options [Integer] :match_threshold
|
93
92
|
# @return [Target] Applitools::Selenium::Target or Applitools::Images::target
|
94
93
|
|
95
|
-
def
|
96
|
-
|
97
|
-
default_match_settings[:match_level] = result.first
|
98
|
-
self.match_level = result.first
|
99
|
-
default_match_settings[:exact] = result.last
|
100
|
-
self.exact = result.last
|
101
|
-
result
|
94
|
+
def set_default_match_settings(value, exact_options = {})
|
95
|
+
(self.match_level, self.exact) = match_level_with_exact(value, exact_options)
|
102
96
|
end
|
103
97
|
|
104
98
|
# Sets default match settings
|
@@ -116,7 +110,21 @@ module Applitools
|
|
116
110
|
"Pasiing extra keys is prohibited! Passed extra keys: #{extra_keys}"
|
117
111
|
)
|
118
112
|
end
|
119
|
-
default_match_settings.merge!
|
113
|
+
result = default_match_settings.merge!(value)
|
114
|
+
self.match_level = result[:match_level]
|
115
|
+
self.exact = result[:exact]
|
116
|
+
self.server_scale = result[:scale]
|
117
|
+
self.server_remainder = result[:remainder]
|
118
|
+
result
|
119
|
+
end
|
120
|
+
|
121
|
+
def default_match_settings
|
122
|
+
{
|
123
|
+
match_level: match_level,
|
124
|
+
exact: exact,
|
125
|
+
scale: server_scale,
|
126
|
+
remainder: server_remainder
|
127
|
+
}
|
120
128
|
end
|
121
129
|
|
122
130
|
def batch
|
data/lib/applitools/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: eyes_core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.11.
|
4
|
+
version: 3.11.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Applitools Team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-08-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: oily_png
|