Appium Tutorial




Hi everyone, thanks for visiting my blog. During my career I have used many android automation tools like Appium, Espresso , Selendroid etc. I have started this blog to share my expereince in simple and short tutorials so that any one who wants to shift from Manual to Automation can do it from the scratch.

Appium is very popularly used Automation Testing toll which supports both android and IOS and hence it is used by many organization. Below are links to the posts of Appium Tutorial which you can explore to start setting up Appium and writing your test cases

Appium Tutorials -

  Advance Appium Tutorials -

     1. Implicit and Explicit Wait in Appium
     2. Database Testing with Appium & JDBC
     3. Creating Maven Project with Appium 
     4. Jenkins Setup for Appium & Maven project
     5. Page Object Model ( POM ) in Appium
     6. Swipe Left, Right , Up & Down using Appium 
     7.How to Test Toast Messages using Appium? 
  
Note - Learn More About Android Studio HERE

71 comments:

  1. This comment has been removed by a blog administrator.

    ReplyDelete
  2. Thanks for sharing your ideas on mobile application.Really useful to me.Continue sharing more like this.
    Regards,
    Mobile Application Training in Chennai | Mobile Apps Testing Training | Mobile Application Testing Training

    ReplyDelete
  3. Hi Anuja Jain

    Can you tell me how to start and stop appium server programmatically using java code in ubuntu OS

    ReplyDelete
    Replies
    1. Sure I will check and share that post as well.. stay connected via social media for latest update

      Delete
    2. Hi you can check this post http://www.qaautomated.com/2016/01/how-to-start-appium-server-using-java.html
      You need to give path as per UNIX Environment and make sure you have install node.js via npm -(Refer http://www.qaautomated.com/2016/11/how-to-install-appium-on-ubuntu.html)

      Delete
  4. Hello Anuja
    can you please help in verifying the toast message in appium

    ReplyDelete
  5. hi getting the below error in appium


    info: [debug] The following desired capabilities were provided, but not recognized by appium. They will be passed on to any other services running on this server. : version
    > info: [debug] Didn't get app but did get Android package, will attempt to launch it on the device
    > info: [debug] Creating new appium session 8ec1d872-bce5-499e-9a5d-0260e353001b
    > info: Starting android appium
    > info: [debug] Getting Java version
    > info: [debug] Cleaning up android objects
    > info: [debug] Cleaning up appium session
    > info: [debug] Error: 'java -version' failed. Error: spawn ENOENT
    > at [object Object]. (C:\Program Files\Appium\node_modules\appium\lib\devices\android\android-common.js:1057:17)
    > at exithandler (child_process.js:633:7)
    > at ChildProcess.errorhandler (child_process.js:649:5)
    > at ChildProcess.EventEmitter.emit (events.js:95:17)
    > at Process.ChildProcess._handle.onexit (child_process.js:795:12)
    > info: [debug] Responding to client with error: {"status":33,"value":{"message":"A new session could not be created. (Original error: 'java -version' failed. Error: spawn ENOENT)","origValue":"'java -version' failed. Error: spawn ENOENT"},"sessionId":null}
    > info: <-- POST /wd/hub/session 500 29.641 ms - 208

    ReplyDelete
  6. Can I tap using screen coordinates If not able to find id etc of elements ?

    ReplyDelete
    Replies
    1. Hi,
      Yes in Appium you can perform tap using co-ordinates.

      Regards,
      Anuja

      Delete
  7. Thank you by the tutorials, I helped me a lot. I am new about moviles test theme and i have a doubt: How am i generate the code of the application who i want to test? that is, the bibliographies almost always give me a example code but they dont tell me where are they generate the test code?
    I would like I know this, please help me.

    ReplyDelete
  8. I started the test´s world with visual studio, microsoft test manager and selenium for web and desktop application the last year, and i liked it.
    At present I am interested in automated mobile testing and i am working with appium and android studio. I have accomplished to do test examples but i dont understand How am i generate the code of the application who i want to test? the examples come with yours code.
    I saw examples with Appium on Mac and i have seen how is it generate the code.
    I have not seen test examples on windows where it is explain the generate test code whit appium and android studio.
    Thank you for yours attention

    ReplyDelete
  9. Thanks for the tutorial, I been searching for this for a long time, At last reached to the got post. Thank you giving a information

    ReplyDelete
  10. I am expecting more interesting topics from you. And this was nice content and definitely it will be useful for many people.
    Mobile App Development Company
    Mobile App Development Company
    Mobile app Development Companies

    ReplyDelete
  11. Exception in thread "main" org.openqa.selenium.remote.UnreachableBrowserException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure.
    Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
    System info: host: 'DESKTOP-1M92PA5', ip: '192.168.0.109', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_121'
    Driver info: driver.version: RemoteWebDriver
    at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:641)


    I m getting this error when i m trying to execute my script. The thing is the the contact to the appium server is not happening

    driver = new RemoteWebDriver(new URL("http://127.0.0.1:4723/wd/hub"),capabilities);
    //driver = new AndroidDriver(new URL("http://172.20.67.130:4723/wd/hub/"), capabilities);
    System.out.println("driver in try method executed");

    I have tried with some other URL and no luck, could anyone help me resolve it ?

    ReplyDelete
  12. Hi,

    how can i select grid view element in appium

    ReplyDelete
  13. can u tell me how to run test case of android without using apk file and using of android source code in android studio

    ReplyDelete
  14. Hi, Good job.. nice tutorials :) is there any real time example source code available? for practicing?
    Thanks, Ranjith

    ReplyDelete
  15. Hello, Anuja!
    I am facing one problem in automating my application.
    I select a radio button first and then try to click OKAY, but what happens is only the radio button gets selected and OKAY button does not.
    Tried the code elsewhere, it runs perfectly.
    Also tried executing following two commands separately, with success.
    Test case gets passed, but actually it does not work.
    Please review the following two commands:

    @Test public void SelectGroupsAndStudents() {

    // Select Group
    driver.findElement(By.xpath("//android.widget.RadioButton[@text='Mahatma Fhule']")).click();

    driver.findElement(By.xpath("//android.widget.RadioButton[@text='Select Groups']")).click();

    Please note that the second command does not get executed.

    Any help will be appreciated!
    Thanks!

    ReplyDelete
  16. Can you please one sample project video.

    ReplyDelete
  17. This comment has been removed by the author.

    ReplyDelete
  18. I believe there are many more pleasurable opportunities ahead for individuals that looked at your site.
    For iPhone Online Training | Android Online Training

    ReplyDelete
  19. Hi,
    Anuja my script is working fine bellow android version 7 but above 7.1 and 8 not working .My appium version is v1.7.2

    ReplyDelete
  20. Any one please tell me how to test toast error messages. Please share code

    ReplyDelete
    Replies
    1. Hi, Check this out - http://www.qaautomated.com/2017/12/how-to-test-toast-messages-using-appium.html

      Delete
    2. Hey Anuja, i have configured appium successfully with android studio now i am facing an issue. I have booking.com app installed on my fone and i am trying to automate but its not working even package and activity is correct. Please help me in resolving this issue.

      Error: cannot start the 'com.booking' application. Orginal error: Error executing abd.exe

      Delete

  21. Thanks for the useful information of software testing courses, give more updates on software testing development, First time I visit your blog really nice, I bookmark your blog here after a daily visit. Learn software testing course in Chennai

    ReplyDelete
  22. Hi Anuja,
    Ashish this side and i am new in appium. Actually I don't find UI automator bat file in my sdk folder. Can you help me please?

    ReplyDelete
    Replies
    1. It will be in bin folder under tools....

      Delete
  23. Hey Anuja, i have configured appium successfully with android studio now i am facing an issue. I have booking.com app installed on my fone and i am trying to automate but its not working even package and activity is correct. Please help me in resolving this issue.

    Error: cannot start the 'com.booking' application. Orginal error: Error executing abd.exe

    ReplyDelete
  24. Hi there... nice blog. I'm specifically looking for Appium with iOS. Can you cover up simple steps for starters on iOS automation using appium?

    ReplyDelete
  25. Nice and informative tutorial of appium.Thanks for sharing such nice article, keep on updating.

    Pega Training in Chennai
    Pega Training

    ReplyDelete
  26. Hello Anuja, thanks for your effort and more grease to your elbow.
    Kindly see the error I am getting when rebuilding my project. Please assist. Thanks.

    build failed 1m 58s 827ms
    Starting Gradle Daemon 9s 596ms
    Run build 1m 32s 408ms
    Load build 2s 74ms
    Evaluate settings 2s 29ms
    Configure build 3s 928ms
    Calculate task graph 8s 77ms
    Run tasks 1m 18s 65ms
    null
    InnerClass annotations are missing corresponding EnclosingMember annotations. Such InnerClass annotations are ignored.
    Default interface methods are only supported starting with Android N (--min-api 24): java.util.Collection com.google.common.collect.BiMap.values()
    Default interface methods are only supported starting with Android N (--min-api 24): boolean com.google.common.base.Predicate.test(java.lang.Object)
    Default interface methods are only supported starting with Android N (--min-api 24): java.util.Collection com.google.common.collect.ListMultimap.get(java.lang.Object)
    null
    com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Users\Eigenaar\AndroidStudioProjects\GoodEnergyApplication\app\libs\guava-25.0-jre.jar
    com.android.builder.dexing.DexArchiveBuilderException: Error while dexing.
    com.android.tools.r8.CompilationFailedException: Compilation failed to complete
    com.android.tools.r8.utils.AbortException

    ReplyDelete
  27. How to relaunch app?

    ReplyDelete
  28. Love to read it,Waiting For More new Update and I Already Read your Recent Post its also nice blog Keep Updating Us..i am following in future also..,

    Best Software Training Institute in Chennai

    Best Online Training Institute in Chennai


    ReplyDelete
  29. Hi Anuja,
    When I copy the apk like (//File f=new File("src/main/java")File fs= new File(f,"Naukri com Job Search_v10.7.apk");)
    inside the project and try to run a script its working as expected from both emulator and real device too.when I try to use to use
    cap.setCapabilities("appPacakge" "com.mobisystems.fileman")
    ca.setCapabilities("appActivity","com.mobisystems.files.FileBrowser")
    I am seeing the below issue
    at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:126)

    ReplyDelete
  30. can you please suggest with correct information ?

    ReplyDelete
  31. Excellent informative blog, Thanks for sharing.
    Wedding Photographer

    ReplyDelete
  32. Nice post By reading your blog, i get inspired and this provides some useful information. Thank you for posting this exclusive post for our vision.
    Digital Marketing Training

    ReplyDelete
  33. Excellent and very cool idea and the subject at the top of magnificence and I am happy to this post..Interesting post! Thanks for writing it.What's wrong with this kind of post exactly? It follows your previous guideline for post length as well as clarity.
    datapower tutorial video

    ReplyDelete
  34. Informative & useful post. Keep it up. Thank you such a great amount for sharing your profitable blog... CA Firms
    Stock Audit
    Inventory Audit

    ReplyDelete
  35. Thanks for giving great kind of information. So useful and practical for me. Thanks for your excellent blog, nice work keep it up thanks for sharing the knowledge.
    dining room interior designer in noida

    ReplyDelete
  36. Thanks for giving great kind of information. So useful and practical for me. Thanks for your excellent blog, nice work keep it up thanks for sharing the knowledge.
    dining room interior designer in noida

    ReplyDelete
  37. nice work keep it up thanks for sharing the knowledge.Thanks for sharing this type of information, it is so useful.
    Epoxy Grout manufacturer in delhi

    ReplyDelete
  38. This is a great post and enlightening post compassionately check this post.
    android app development

    ReplyDelete
  39. Thanks for sharing. I really liked your post, keep sharing!!

    CEH Training In Hyderbad

    ReplyDelete
  40. Thank you so much for the tutorials. Very helpful.

    ReplyDelete
  41. Wonderful post.I learned some new things from your post.Really enjoying your sharing, you have a great teaching style and make these new concepts much easier to understand. Thanks.Really enjoying your sharing, you have a great teaching style and make these new concepts much easier to understand. Thanks.Training with placement in Hyderabad

    ReplyDelete
  42. I feel happy about and learning more about this topic. keep sharing your information regularly for my future reference. This content creates a new hope and inspiration with in me. Thanks for sharing article like this. the information which you have provided is better then other blog.
    Best IELTS Coaching in Dwarka sector 7

    ReplyDelete
  43. Hey Anuja,
    I am working on Mobile application as Manual QA.Now I need to start working on Automation part.What do you suggest.Which tool Appium or Espresso I should use and why ?.
    Ankit

    ReplyDelete
  44. I love this post.

    โปรโมชั่นGclub ของทางทีมงานตอนนี้แจกฟรีโบนัส 50%
    เพียงแค่คุณสมัคร Gclub กับทางทีมงานของเราเพียงเท่านั้น
    ร่วมมาเป็นส่วนหนึ่งกับเว็บไซต์คาสิโนออนไลน์ของเราได้เลยค่ะ
    สมัครสมาชิกที่นี่ >>> Gclub online

    ReplyDelete
  45. Very cool!

    เว็บไซต์คาสิโนออนไลน์ที่ได้คุณภาพอับดับ 1 ของประเทศ
    เป็นเว็บไซต์การพนันออนไลน์ที่มีคนมา สมัคร Gclub Royal1688
    และยังมีเกมส์สล็อตออนไลน์ 1688 slot อีกมากมายให้คุณได้ลอง
    สมัครสมาชิกที่นี่ >>> Gclub Royal1688

    ReplyDelete
  46. Thanks for Sharing this great article..Its really nice and useful for us… keep sharing..
    AWS Training In Hyderabad

    ReplyDelete
  47. Nice post. Thanks for sharing! I want people to know just how good this information is in your article. It’s interesting content and Great work.
    Thanks & Regards,
    VRIT Professionals,
    No.1 Leading Web Designing Training Institute In Chennai.

    And also those who are looking for
    Web Designing Training Institute in Chennai
    SEO Training Institute in Chennai
    Photoshop Training Institute in Chennai
    PHP & Mysql Training Institute in Chennai
    Android Training Institute in Chennai

    ReplyDelete
  48. Just now I read your blog, it is very helpful nd looking very nice and useful information.
    Digital Marketing Online Training
    Servicenow Online Training
    EDI Online Training

    ReplyDelete
  49. I enjoyed over read your blog post. Your blog have nice information, I got good ideas from this amazing blog. I am always searching like this type blog post. I hope I will see again.
    Best Web Development Institute Delhi
    Top Company to Develop website in PHP
    Best Website Development Services
    Website Redesign Services
    Best Graphic Design Agency Rohini
    Digital Marketing Company in North Delhi
    Web Services

    ReplyDelete
  50. Can you please let me know, how to identify the locators in File Manager app using Appium

    ReplyDelete