UI Testing with Puppeteer: Implement end-to-end testing and browser automation using JavaScript and Node.js
暫譯: 使用 Puppeteer 進行 UI 測試:利用 JavaScript 和 Node.js 實現端到端測試及瀏覽器自動化
Kondratiuk, Dario
- 出版商: Packt Publishing
- 出版日期: 2021-03-11
- 售價: $1,670
- 貴賓價: 9.5 折 $1,587
- 語言: 英文
- 頁數: 316
- 裝訂: Quality Paper - also called trade paper
- ISBN: 180020678X
- ISBN-13: 9781800206786
-
相關分類:
JavaScript、Node.js、Puppet、使用者介面 UI
海外代購書籍(需單獨結帳)
商品描述
Write fail-safe automation tests, device emulation, and browser automation using Puppeteer's Google-powered API
Key Features:
- Get up and running with Puppeteer and discover best practices for automation testing
- Automate your modern web applications using Jest and Mocha with Puppeteer
- Generate screenshots using Puppeteer and find out how they can be used for UI regression tests
Book Description:
Puppeteer is an open source web automation library created by Google to perform tasks such as end-to-end testing, performance monitoring, and task automation with ease. Using real-world use cases, this book will take you on a pragmatic journey, helping you to learn Puppeteer and implement best practices to take your automation code to the next level!
Starting with an introduction to headless browsers, this book will take you through the foundations of browser automation, showing you how far you can get using Puppeteer to automate Google Chrome and Mozilla Firefox. You'll then learn the basics of end-to-end testing and understand how to create reliable tests. You'll also get to grips with finding elements using CSS selectors and XPath expressions. As you progress through the chapters, the focus shifts to more advanced browser automation topics such as executing JavaScript code inside the browser. You'll learn various use cases of Puppeteer, such as mobile devices or network speed testing, gauging your site's performance, and using Puppeteer as a web scraping tool.
By the end of this UI testing book, you'll have learned how to make the most of Puppeteer's API and be able to apply it in your real-world projects.
What You Will Learn:
- Understand browser automation fundamentals
- Explore end-to-end testing with Puppeteer and its best practices
- Apply CSS Selectors and XPath expressions to web automation
- Discover how you can leverage the power of web automation as a developer
- Emulate different use cases of Puppeteer such as network speed tests and geolocation
- Get to grips with techniques and best practices for web scraping and web content generation
Who this book is for:
The book is for testing professionals, QA engineers, and test automation enthusiasts who want to perform end-to-end testing using Google's developer tools. Web developers who want to learn how to use Puppeteer for generating content, scraping websites, and evaluating website performance will find this book useful. Although knowledge of Node.js isn't necessary, basic JavaScript knowledge will assist with understanding the concepts covered.
商品描述(中文翻譯)
撰寫故障安全的自動化測試、設備模擬和使用 Puppeteer 的瀏覽器自動化
主要特點:
- 快速上手 Puppeteer,並發現自動化測試的最佳實踐
- 使用 Jest 和 Mocha 與 Puppeteer 自動化現代網頁應用程式
- 使用 Puppeteer 生成截圖,並了解如何將其用於 UI 回歸測試
書籍描述:
Puppeteer 是由 Google 創建的開源網頁自動化庫,旨在輕鬆執行端到端測試、性能監控和任務自動化等任務。本書將通過真實案例,帶您踏上實用的旅程,幫助您學習 Puppeteer 並實施最佳實踐,將您的自動化代碼提升到一個新水平!
本書從無頭瀏覽器的介紹開始,將帶您了解瀏覽器自動化的基礎,展示您如何使用 Puppeteer 自動化 Google Chrome 和 Mozilla Firefox。接著,您將學習端到端測試的基本概念,並了解如何創建可靠的測試。您還將掌握使用 CSS 選擇器和 XPath 表達式查找元素的技巧。隨著章節的進展,重點將轉向更高級的瀏覽器自動化主題,例如在瀏覽器內執行 JavaScript 代碼。您將學習 Puppeteer 的各種使用案例,例如移動設備或網絡速度測試、評估網站性能,以及將 Puppeteer 作為網頁爬蟲工具的使用。
在這本 UI 測試書的結尾,您將學會如何充分利用 Puppeteer 的 API,並能夠將其應用於您的實際項目中。
您將學到什麼:
- 理解瀏覽器自動化的基本原理
- 探索使用 Puppeteer 進行端到端測試及其最佳實踐
- 將 CSS 選擇器和 XPath 表達式應用於網頁自動化
- 發現作為開發者如何利用網頁自動化的力量
- 模擬 Puppeteer 的不同使用案例,例如網絡速度測試和地理位置
- 掌握網頁爬蟲和網頁內容生成的技術及最佳實踐
本書適合誰:
本書適合測試專業人員、QA 工程師和希望使用 Google 的開發者工具進行端到端測試的測試自動化愛好者。希望學習如何使用 Puppeteer 生成內容、爬取網站和評估網站性能的網頁開發者將會發現本書非常有用。雖然不需要具備 Node.js 的知識,但基本的 JavaScript 知識將有助於理解所涵蓋的概念。