Ruby: Testing with RSpec
Offered By: LinkedIn Learning
Course Description
Overview
Learn how to use RSpec, the Ruby testing framework that can help developers be more productive, write better code, and reduce bugs during development.
Syllabus
Introduction
- Welcome
- How to use the exercise files
- What is RSpec?
- Why software tests are important
- Thinking in user stories
- Writing good tests
- Installing Ruby and RubyGems
- Installing RSpec
- Configuration
- Target code and the spec file
- Basic syntax
- Writing specs
- Running specs
- Skipping examples and working with pending examples
- Fundamentals
- A deprecated modifier: should
- Equivalence matchers
- Truthiness matchers
- Numeric comparison matchers
- Collections
- Other useful matchers
- Predicate matchers
- Observation matchers
- Complex expectations
- Helper methods
- Hooks: before, after, and around
- Using the let method
- Setting a subject
- Implicitly defined subjects
- Shared examples
- What are test doubles?
- Using mocks and stubs
- Partial test doubles
- Message expectations
- Message argument constraints
- Message count constraints
- Spies
- Food-finder application
- Challenge: NumberHelper
- Solution: NumberHelper
- Challenge: StringExtend
- Solution: StringExtend
- Challenge: Restaurant
- Solution: Restaurant
- Challenge: Guide
- Solution: Guide
- Installing
- Generators
- Test database
- Transactional examples
- Model specs
- Helper specs
- Controller specs: Requests
- Controller specs: Responses
- View specs
- What is TDD?
- A TDD example: Part one
- A TDD example: Part two
- A TDD example: Part three
- A TDD example: Part four
- Benefits and disadvantages
- Fixtures and factories
- Acceptance testing
- Automatic testing
- Other tools
- Goodbye
Taught by
Kevin Skoglund
Related Courses
A Practical Introduction to Test-Driven DevelopmentLearnQuest via Coursera Advanced TestNG Framework and Integration with Selenium
Coursera Project Network via Coursera API Testing Using Rest Sharp (with C#) Test Automation Tool
Coursera Project Network via Coursera Apply basic testing for your Django web application
Coursera Project Network via Coursera Black-box and White-box Testing
University of Minnesota via Coursera