Sha256: 6fc73a3f85ddfbb58f5c13ac5ca6ef8172a4465b37f852429adb5fda30b4f18e

Contents?: true

Size: 291 Bytes

Versions: 3

Compression:

Stored size: 291 Bytes

Contents

module Calabash
  # @!visibility private
  module Patch

    # @!visibility private
    module Array
      def to_pct
        if length != 2
          raise RangeError, "Cannot convert #{self} to {:x, :y} hash"
        end

        {x: self.[](0), y: self.[](1)}
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
calabash-1.9.9.pre3 lib/calabash/patch/array.rb
calabash-1.9.9.pre2 lib/calabash/patch/array.rb
calabash-1.9.9.pre1 lib/calabash/patch/array.rb