Sha256: b4535e48f199e225ee66e53da1124ac02bfea86053145d6f3bc39ee44caa0f24

Contents?: true

Size: 897 Bytes

Versions: 15

Compression:

Stored size: 897 Bytes

Contents

require 'brazenhead'

module Gametel
  module Platforms
    module View

      def click_on_view_by_id(id)
        get_view_by_id(id) do |device|
          device.click_on_view('@@the_view@@', :target => 'Robotium')
        end
      end

      def get_view_by_id(id, &block)
        chain_calls do |device|
          device.id_from_name(id, :target => 'Brazenhead', :variable => '@@view_id@@')
          device.get_view('@@view_id@@', :target => 'Robotium', :variable => '@@the_view@@')
          block.call device if block
        end
      end

      def get_view_by_index(clazz, index, &block)
        chain_calls do |device|
          device.get_class
          device.for_name clazz, :variable => '@@the_type@@'
          device.get_view '@@the_type@@', index, :target => 'Robotium', :variable  => '@@the_view@@'
          block.call device if block
        end
      end

    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
gametel-0.7 lib/gametel/platforms/brazenhead/view.rb
gametel-0.6 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.9.3 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.9.2 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.9.1 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.9 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.8.1 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.8 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.7 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.6 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.5 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.4 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.3 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.2 lib/gametel/platforms/brazenhead/view.rb
gametel-0.5.1 lib/gametel/platforms/brazenhead/view.rb