1. Assert, this allows the test to check if the element is on the page, if it is not available then the test will stop on the step that failed.
  2. Verify, allows the test to check the element is on the page, but if it isn't then the test will carry on executing
  3. AJAX stands for Asynchronous JavaScript And XML due to the facts that it relies on JavaScript creating asynchronous calls and then returning XML with the data that the user or application requires to carry on.
  4. AJAX applications do not have the items needed for the tests when the tests get to commands. To get around this we had a look at adding waitFor commands to the tests. This is due to the fact that Selenium does not implicitly wait for elements to appear in the page.
  5. Elements should have an ID attribute for all their controls on the page. A control would be an element that we can interact with and is not static text.
  6. Having // as the start of your XPath is seen as a greedy query since it will parse the entire DOM until it finds the element that you want to find.
  7. Xpath = //element[@attribute=’attribute value’]
  8. WebDriver tries to control the browser from outside the browser. It uses accessibility API to drive the browser.
  9. We can create an object that represents the page and then pass the Selenium object in the programming language.
  10. Page Object: this is a technique where we split the test logic out into separate classes. This allows us to create a Java class for each of the pages that we use on the page.
  11. Page Factory: this allows us to decorate our WebElement variables in our page objects so that we remove a lot of the look up code
  12. All the methods for doing actions to the web application like typing and clicking require that we find the element first
  13. findElementByID(String using), the using variable takes the ID of the element that you wish to look for. It will return a WebElement object that we can then work with
  14. findElement calls will return a WebElement object that we can perform actions on
  15. findElementByClassName(). If there is more than one element on the page that has this class name, then it will return the first element that it gets
  16. Finding if an element exists without throwing an error: use the findElements() call, and then we just need to check that the size of the list returned is 0
  17. Selenium Grid is a version of Selenium that allows teams to set up a number of Selenium instances and then have one central point to send your Selenium commands to.
  18. Selenium Grid works by having a central point that tests can connect to, and then commands are pushed to Selenium server nodes that are connected to the hub. The hub has a web interface that tells you about the Selenium Server and the browser instances connected to the hub and if they are currently in use.
  19. Screenshots capability lives within an interface called TakesScreenshot. We will cast the driver to this and then use the interface to access getScreenshotAs() method. You will also need to import the following library: import static openqa.selenium.OutputType.*;
  20. Capturing images as base64 strings: String screenshotBase64 = ((Screenshot)driver).getScreenshotAs(base64);
  21. Saving images to bytes: Bytes screenbytes = ((Screenshot)driver).getScreenshotAs(bytes);
  22. Saving screenshots to files:  File saveImage = ((Screenshot)driver).getScrennshotAs(file)
  23. Verify allows a test to continue and keep track of all verify errors. Assert will stop a test immediately when the assert fails
  24. The Page Object design pattern gives us a way to abstract our tests away so that we can make these tests more maintainable. We can make tests that only require updating if new steps have been added, otherwise it just requires the page object to be updated
  25. Using ChromeDriver, the PATH environment variable needs to be set with where the ChromeDriver executable lives. This is so that when we call ChromeDriver with our Java code, it will load the relevant executable and load the browser as quickly as possible

[Selenium.2.Testing.Tools.Beginners.Guide]读书笔记的更多相关文章

  1. [Spring Boot Reference Guide] 读书笔记一 Getting Started

    8. Introducing Spring Boot Goals of spring boot: Provide a radically faster and widely accessible ge ...

  2. advanced bash shell guide读书笔记

    http://note.youdao.com/noteshare?id=fc23a679849b4627d131d3ef07c74a71

  3. 读书笔记-实用单元测试(英文版) Pragmatic Unit Testing in C# with NUnit

    读书笔记-实用单元测试(英文版) Pragmatic Unit Testing in C# with NUnit Author: Andrew Hunt ,David Thomas with Matt ...

  4. 读书笔记-Software Testing(By Ron Patton)

    Software Testing Part I:The Big Picture 1.Software Testing Background Bug's formal definition 1.The ...

  5. 【Tools】Pro Git 一二章读书笔记

    记得知乎以前有个问题说:如果用一天的时间学习一门技能,选什么好?里面有个说学会Git是个很不错选择,今天就抽时间感受下Git的魅力吧.   Pro Git (Scott Chacon) 读书笔记:   ...

  6. 读书笔记:《梦断代码Dreaming in Code》

    读书笔记:<梦断代码Dreaming in Code> 拿到<梦断代码>书后,一口气翻了一遍,然后又用了3天时间仔细读了一遍,也不禁掩卷长叹一声,做软件难.虽难,仍要继续走下去 ...

  7. SystemTap Beginners Guide

    SystemTap 3.0 SystemTap Beginners Guide Introduction to SystemTap Edition 3.0   Red Hat, Inc. Don Do ...

  8. The Pragmatic Programmer 读书笔记之中的一个 DRY-Don’t Repeat Youself

     The Pragmatic Programmer读书笔记之中的一个 DRY-Don't Repeat Youself 尽管自己买了非常多软件project方面的书,可是由于时间的问题.一直没有静 ...

  9. HDFS Federation (读书笔记)

    HDFS Federation (读书笔记) HDFS的架构 HDFS包含两个层次:命名空间管理(Namespace) 和 块/存储管理(Block Storage). 命名空间管理(Namespac ...

随机推荐

  1. Openlayers2中统计图的实现

    概述: 在前文中.介绍了Arcgis for js和Openlayers3中统计图的实现.在本文,书接上文.介绍在Openlayers2中,统计图的实现. 实现: 在Openlayers2中,popu ...

  2. Photoshop做32位带Alpha通道的bmp图片

    原文链接: http://blog.sina.com.cn/s/blog_65c0cae801016e5u.html   批量制作32位带Alpha通道的bmp图片,可以制作一个动作,内容可以如下: ...

  3. C#基础第七天-作业答案-利用面向对象的思想去实现名片-动态添加

    class Card { private string name; public string Name { get { return name; } set { name = value; } } ...

  4. Java:concurrent包下面的Map接口框架图(ConcurrentMap接口、ConcurrentHashMap实现类)

    Java集合大致可分为Set.List和Map三种体系,其中Set代表无序.不可重复的集合:List代表有序.重复的集合:而Map则代表具有映射关系的集合.Java 5之后,增加了Queue体系集合, ...

  5. Go基础--终端操作和文件操作

    终端操作 操作终端相关的文件句柄常量os.Stdin:标准输入os.Stdout:标准输出os.Stderr:标准错误输出 关于终端操作的代码例子: package main import " ...

  6. 坊间流传着的关于谷歌大牛Jeff Dean的传说

    Jeff Dean,Google的软件架构天才.Google大型并发编程框架Map/Reduce作者. 在Google,公司最顶尖的编程高手Jeff Dean曾发明过一种先进的方法,该方法可以让一个程 ...

  7. Atitit 爬虫 node版 attilaxA

    Atitit 爬虫 node版 attilax 1.1. 貌似不跟python压实,,java的webmagic压实,,什么爬虫框架也没有,只好自己写了. 查了百度三爷资料也没有.都是自己写.. 1. ...

  8. [sql]mysql指引(整理中...)-对db的分类

    参考 db存储及分层 一个db一个文件夹. 一张表两个文件frm是存表结构的,ibd是存数据的 连接层: sock ip sql层: 存储层: 2018年4月1日 20:53:54小结: 时间太久,抓 ...

  9. Linux 常见紧急情况处理方法

    使用急救盘组进行维护 急救盘组(也称为 boot/root 盘组),是系统管理员必不可少的工具.用它可以独立地启动和运行一个完整的 Linux 系统.实际上,急救盘组中的第 2 张盘上就有一个完整的 ...

  10. IE报错:The given path's format is not supported

    在使用FileUpload控件进行上传EXCEL文件时,本地调试上传无问题,但是发布之后报地址无效错误 一.出现这个错误的主要原因是,在本地上传图片的时候HttpPostedFileBase对象里面保 ...