Sha256: cecaeff7db6665d576cad08e4298a67d47d274d4a24a7f36fe2abf90912d2dd5

Contents?: true

Size: 1.3 KB

Versions: 10

Compression:

Stored size: 1.3 KB

Contents

# rake android['android/element/generic']
describe 'android/element/generic' do
  def content
    'Content'
  end

  def partial
    'tent'
  end

  t 'find works before and after get_source' do
    wait { find(partial).text.must_equal content }
    wait { get_source.class.must_equal String }
    wait { find(partial).text.must_equal content }
  end

  t 'find' do
    wait { find(partial).text.must_equal content }
  end

  t 'finds' do
    wait { finds(partial).first.text.must_equal content }
  end

  t 'find_exact' do
    wait { find_exact(content).text.must_equal content }
  end

  t 'finds_exact' do
    wait { finds_exact(content).first.text.must_equal content }
  end

  # scroll_to is broken
  t 'scroll_to' do
    wait { find('Views').click }
    wait { scroll_to('scrollbars').text.must_equal 'ScrollBars' }

    wait { find('ScrollBars').click }
    wait { text('style').click }
    wait { scroll_to('Developers', 1).text.must_include 'What would it take to build a better mobile phone?' }
    back
    back
    # back to start activity
    back
  end

  t 'scroll_to_exact' do
    wait { find('Views').click }

    wait { scroll_to_exact('ScrollBars').text.must_equal 'ScrollBars' }
    wait { find('ScrollBars').click }
    wait { text('style').click }
    back
    back
    # back to start activity
    back
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
appium_lib-9.4.5 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.4.4 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.4.3 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.4.2 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.4.1 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.4.0 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.3.8 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.3.7 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.3.6 android_tests/lib/android/specs/android/element/generic.rb
appium_lib-9.3.5 android_tests/lib/android/specs/android/element/generic.rb