From 35d98aadc8fe3056761ab47ec9f6948ba0e0e02b Mon Sep 17 00:00:00 2001 From: David Chelimsky Date: Mon, 9 Apr 2012 22:48:30 -0500 Subject: [PATCH] add start_with and end_with matchers to README [ci skip] --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 29d347e23..1b4426cc7 100644 --- a/README.md +++ b/README.md @@ -129,6 +129,8 @@ actual.should have_xxx(:arg) # passes if actual.has_xxx?(:arg) ```ruby actual.should include(expected) +actual.should start_with(expected) +actual.should end_with(expected) ``` #### Examples @@ -136,8 +138,14 @@ actual.should include(expected) ```ruby [1,2,3].should include(1) [1,2,3].should include(1, 2) +[1,2,3].should start_with(1) +[1,2,3].should start_with(1,2) +[1,2,3].should end_with(3) +[1,2,3].should end_with(2,3) {:a => 'b'}.should include(:a => 'b') "this string".should include("is str") +"this string".should start_with("this") +"this string".should end_with("ring") ``` ## Also see