Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

improved readme syntax

  • Loading branch information...
commit 70b4841fba2207cc50f21c7b5c0cfb3b7e61b3ab 1 parent 988cc08
@andykent authored
Showing with 9 additions and 1 deletion.
  1. +9 −1 README.markdown
View
10 README.markdown
@@ -6,6 +6,14 @@ Getting Started (With Screw.Unit)
---------------------------------
See `spec/suite.html` and the test file `screw_integration_spec.js` for lots of real world usage examples.
+but you will need to include the Smoke files and you can get straight to work using the mock() and spec() methods...
+
+ foo = {bar: function(attribute){return 'hello'}, baz:'goodbye'};
+ stub(foo, 'baz').and_return('hi!');
+ myMock = mock('test');
+ myMock.should_receive('foo').at_least('once').and_return('hello');
+ expect(foo.baz).to(equal, 'hi!');
+
Getting Started (Free Standing)
-------------------------------
Include the library files in your document...
@@ -26,7 +34,7 @@ Create your mocks...
Create your expectations...
- myMock.should_receive('foo').exactly('once').and_return('bar');
+ myMock.should_receive('foo').exactly(3, 'times').and_return('bar');
Check you expectations...
Please sign in to comment.
Something went wrong with that request. Please try again.