官术网_书友最值得收藏!

What this book covers

Chapter 1, Welcome to BDD, presents the basic concepts that act as a foundation for BDD. Its goal is to debunk a few false preconceptions about BDD and to clarify its nomenclature. It is the only theoretical chapter in the whole book.

Chapter 2, Automating Tests with Mocha, Chai, and Sinon, introduces the basic tools for testing in JavaScript. We will go through the installation process and some simple examples of testing. You can safely skip this chapter if you are well versed with these tools.

Chapter 3, Writing BDD Features, presents some techniques for transforming a functional requirement written in normal language into a set of automated BDD tests or features. We will write our first BDD feature.

Chapter 4, Cucumber.js and Gherkin, repeats the exercise of the previous chapter but this time using Cucumber.js. This way we can compare it fairly with Mocha. You can safely skip this chapter if you already know Cucumber.js.

Chapter 5, Testing a REST Web API, shows you how to test not only the core logic, but also the Node.js server that publishes a Web API. This chapter will be of special interest if you are writing a REST API.

Chapter 6, Testing a UI Using WebDriverJS, shows you how to approach testing the UI layer from the perspective of BDD. You will also learn about WebDriverJS and how it can help you in this task.

Chapter 7, The Page Object Pattern, explains how to create robust UI tests that are less susceptible to being broken by UI design changes. For that, we will apply the page object pattern.

Chapter 8, Testing in Several Browsers with Protractor and WebDriver, shows you how to use the Protractor framework to run your test suite in several browsers.

Chapter 9, Testing Against External Systems, gives you some basic techniques for doing this and, most important, shows you when not to do it. Although this kind of test is not strictly BDD, sometimes you do need to test against external systems.

Chapter 10, Final Thoughts, briefly summarizes the book and clarifies the right granularity for BDD testing. It will also tell you whether to do only BDD at the core business level, or add additional tests at other levels.

主站蜘蛛池模板: 阜平县| 武宣县| 河间市| 霍邱县| 岳西县| 商洛市| 呼图壁县| 黎平县| 鲜城| 进贤县| 自治县| 繁昌县| 乌拉特前旗| 蒲江县| 遂平县| 临城县| 乳山市| 额济纳旗| 岳阳县| 谢通门县| 鲁甸县| 西乌珠穆沁旗| 聂拉木县| 汉源县| 武鸣县| 衢州市| 南投市| 林口县| 河源市| 三明市| 米脂县| 泗水县| 临洮县| 汉川市| 井研县| 田林县| 调兵山市| 镇原县| 皋兰县| 徐州市| 阿拉善右旗|