Skip to content

Commit f667e4b

Browse files
committed
rb - unnecessary element equality abstraction
1 parent 1db76fd commit f667e4b

File tree

3 files changed

+1
-9
lines changed

3 files changed

+1
-9
lines changed

rb/lib/selenium/webdriver/common/element.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def inspect
3737
end
3838

3939
def ==(other)
40-
other.kind_of?(self.class) && bridge.elementEquals(self, other)
40+
other.kind_of?(self.class) && ref == other.ref
4141
end
4242
alias_method :eql?, :==
4343

rb/lib/selenium/webdriver/remote/bridge.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -595,10 +595,6 @@ def getElementValueOfCssProperty(element, prop)
595595
execute :getElementValueOfCssProperty, :id => element, :property_name => prop
596596
end
597597

598-
def elementEquals(element, other)
599-
element.ref == other.ref
600-
end
601-
602598
#
603599
# finding elements
604600
#

rb/lib/selenium/webdriver/remote/w3c_bridge.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -574,10 +574,6 @@ def getElementValueOfCssProperty(element, prop)
574574
execute :getElementCssValue, :id => element, :property_name => prop
575575
end
576576

577-
def elementEquals(element, other)
578-
element.ref == other.ref
579-
end
580-
581577
#
582578
# finding elements
583579
#

0 commit comments

Comments
 (0)