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

Chapter 2. Specifying Behavior with Examples and Matchers

In this chapter, we'll see how RSpec's examples and matchers implement the general testing concepts of units and assertions. An example is the base unit for a set of RSpec specs and, within it, you must have a matcher to assert something, otherwise it would serve no purpose.

In this chapter, we will cover the following topics:

  • Structure of a spec file
  • RSpec output
  • Matchers
  • The let helper
  • Testing for errors
主站蜘蛛池模板: 河间市| 渝北区| 临安市| 唐海县| 万州区| 盐池县| 鲁山县| 金塔县| 澎湖县| 崇礼县| 家居| 阜南县| 高密市| 通许县| 扶沟县| 东山县| 东海县| 永吉县| 政和县| 夏河县| 南投市| 砚山县| 邻水| 泰安市| 东辽县| 青海省| 长岭县| 乐都县| 天镇县| 娄底市| 灵璧县| 安徽省| 西林县| 呼伦贝尔市| 宜城市| 疏附县| 福建省| 西安市| 甘南县| 巴里| 博乐市|