Back to Browse

Structuring Tests - Testing Rails with RSpec Tutorial pt 2

1.1K views
Dec 19, 2022
9:47

This video covers: 0:15 - Context blocks 4:07 - RSpec let 6:16 - described_class 7:17 - subject 7:59 - Simplifying tests with subject and 1-line expectations In this video I'll cover how to use context blocks, within RSpec describe blocks, to test different cases. I'll cover RSpec's let feature and explain how to use it to simplify your tests. Lastly I'll cover RSpec's `described_class` and `subject` methods and explain how to use them with a real world example.

Download

1 formats

Video Formats

360pmp411.7 MB

Right-click 'Download' and select 'Save Link As' if the file opens in a new tab.

Structuring Tests - Testing Rails with RSpec Tutorial pt 2 | NatokHD