Javascript TDD for Rubyists
summary
Shows how to use Jasmine with RSpec in Rails by installing the jasmine gem and running the Rails generator, running the browser runner on port 8888 or automating with rake jasmine:ci which uses Selenium, and how RSpec can write view fixtures into tmp for specs to use. Demonstrates spies and stubs including andCallThrough, matchers like toBeTruthy vs falsy quirks, and expect(...).toHaveBeenCalledWith arguments, with tests that run hundreds in a tenth of a second.
AI-written summary · about
chapters (14)
- 0:00Start
- 4:15Drives Good Design
- 5:51Focus and Process
- 7:41"Free" Documentation
- 9:21Ripped Off RSpec
- 10:00RSpec Integration
- 12:44$ rake jasmine
- 14:47Spec Suites
- 15:27Examples / Expectations
- 19:11Custom Matchers
- 21:58Stubbing Values
- 23:50Message Expectations
- 28:15Error Expectations
- 29:46Simulating Errors
related talks
18mStart using Jasmine. Write better JavaScript. Profit.
40mTesting Javascript with Jasmine
35mFrom RSpec to Jest: JavaScript testing for Rails devs
35mFrom RSpec to Jest: JavaScript testing for Rails devs
16mEnvjs and Jasmine: Headless tests FTW
49mFront End Testing Frontier
31mQuick and easy browser testing using RSpec and Rails 5.1
01h 19mBDD and Acceptance Testing with RSpec & Capybara
