<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>lib/images/bg.png</filename>
    </added>
    <added>
      <filename>lib/images/hr.png</filename>
    </added>
    <added>
      <filename>lib/images/loading.gif</filename>
    </added>
    <added>
      <filename>lib/images/sprites.bg.png</filename>
    </added>
    <added>
      <filename>lib/images/sprites.png</filename>
    </added>
    <added>
      <filename>lib/images/vr.png</filename>
    </added>
    <added>
      <filename>lib/jspec.css</filename>
    </added>
    <added>
      <filename>lib/jspec.jquery.js</filename>
    </added>
    <added>
      <filename>lib/jspec.js</filename>
    </added>
    <added>
      <filename>lib/jspec.xhr.js</filename>
    </added>
    <added>
      <filename>modules/jspec.jsocka.js</filename>
    </added>
    <added>
      <filename>spec/module.html</filename>
    </added>
    <added>
      <filename>spec/spec.module.js</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -30,19 +30,30 @@ Here are some usage examples
 
 Usage Notes
 -----------
-Please note that every JSocka method is a function, not a parameter. While Mocha does support some syntax like `Person.expects(method).once`, there's not a way to implement this in Javascript. Everything needs parentheses!
+Please note that every JSocka method is a function, not a parameter. While Mocha does support some syntax like `Person.expects(method).once`, there's not a way to implement this in Javascript. Everything needs parentheses! The only exception to this is when using `JSocka(&quot;Object&quot;).any_instance.stubs()`
 
 Expectations are destructive (Adding hook code with chaining doesn't work for base classes). Be aware that `JSocka(&quot;Person&quot;).expects(&quot;speak&quot;)` will keep track of how many times the `Person.speak` method is called, but `Person.speak` will not return anything unless you explicitly define it, i.e. `JSocka(&quot;Person&quot;).expects(&quot;speak&quot;).returns(&quot;function(){ // code}&quot;)`
 
-Recently Added (Read: Tested, but not thoroughly) Features
-----------------------------------------------------------
+JSpec Integration
+-----------------
+The `modules/jspec.jsocka.js` file is a module that extends JSpec functionality. This includes
+* `Object.stubs` syntax, instead of `JSocka(&quot;Object&quot;).stubs`. This works with `expects` and `any_instance` as well.
+* Automatic expectation-checking and destubbing after every spec. For example, the following spec will automatically fail:
+    describe &quot;Example&quot;
+      it &quot;should fail&quot;
+        Object.expects(&quot;my_method&quot;)
+      end
+    end
+JSpec will automatically hook into the errors collection and display them with the test. 
+
+Recently Added Features
+-----------------------
+* JSpec module integration
 * Times conditions on expectations
 * With conditions on expectations
 
 On the Horizon
 --------------
-* Finishing implementation for &quot;expects&quot;
-* Creating matchers for JSpec to allow `Person.stubs(&quot;speak&quot;).returns(&quot;function(){}&quot;)`
 * Removing `function(){}` dependencies for `returns()`
 * Parsing properties vs. functions
 </diff>
      <filename>README.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -90,12 +90,13 @@ function JSocka(object){
   };
 }
 
-JSocka.destub = function(){
+JSocka.clearStubs = function(){
   for(object in JSocka.stubbed){
     for(method in JSocka.stubbed[object]){
       eval(object+'.'+method+'=JSocka.stubbed[object][method][&quot;method&quot;]');
     };
   };
+  JSocka.stubbed = {};
 }
 
 JSocka.hasExpectations = function(){</diff>
      <filename>lib/jsocka.js</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
 describe &quot;JSocka(object)&quot;
   before_each
-    JSocka.destub()
+    JSocka.clearStubs()
   end
   describe &quot;.stubs(method)&quot;
     describe &quot;.returns(method)&quot;
@@ -33,12 +33,12 @@ describe &quot;JSocka(object)&quot;
       end
     end
   end
-  describe &quot;.destub()&quot;
+  describe &quot;.clearStubs()&quot;
     it &quot;should remove all class and instance method stubs&quot;
       a = new Apple(&quot;Red Delicious&quot;)
       JSocka(&quot;Apple&quot;).stubs(&quot;getType&quot;).returns(&quot;function(){return 'A Vegetable'}&quot;)
       JSocka(&quot;Apple&quot;).any_instance.stubs(&quot;getType&quot;).returns(&quot;function(){return 'Granny Smith'}&quot;)
-      JSocka.destub()
+      JSocka.clearStubs()
       a.getType().should_equal &quot;Red Delicious&quot;
       Apple.getType().should_equal &quot;A Fruit&quot;
     end
@@ -62,14 +62,16 @@ describe &quot;JSocka(object)&quot;
         Apple.getType().should_equal &quot;A Vegetable&quot;
       end
       it &quot;should not affect an instance method of the same name&quot;
-
+        JSocka(&quot;Apple&quot;).expects(&quot;getType&quot;).returns(&quot;function(){return 'A Vegetable'}&quot;)
+        a = new Apple(&quot;Red Delicious&quot;)
+        a.getType().should_equal &quot;Red Delicious&quot;
       end
     end
     describe &quot;.never()&quot;
       it &quot;should throw an error if the stubbed method is called&quot;
         JSocka(&quot;Apple&quot;).expects(&quot;getType&quot;).never()
         Apple.getType() 
-        -{JSocka.checkExpectations()}.should_throw_error
+        JSocka.errors().should.include &quot;Apple&quot;
       end
     end
   end</diff>
      <filename>spec/spec.stubbing.js</filename>
    </modified>
    <modified>
      <diff>@@ -1,22 +1,26 @@
 &lt;html&gt;
 	&lt;head&gt;
-		&lt;link type=&quot;text/css&quot; rel=&quot;stylesheet&quot; href=&quot;lib/jspec.css&quot; /&gt;
-		&lt;script src=&quot;lib/jspec.js&quot;&gt;&lt;/script&gt;
+		&lt;link type=&quot;text/css&quot; rel=&quot;stylesheet&quot; href=&quot;../lib/jspec.css&quot; /&gt;
+		&lt;script src=&quot;http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js&quot;&gt;&lt;/script&gt;
+		&lt;script src=&quot;../lib/jspec.js&quot;&gt;&lt;/script&gt;
+		&lt;script src=&quot;../lib/jspec.jquery.js&quot;&gt;&lt;/script&gt;
+		&lt;script src=&quot;../lib/jspec.xhr.js&quot;&gt;&lt;/script&gt;
 
                 &lt;script src=&quot;apple.js&quot;&gt;&lt;/script&gt;
                 &lt;script src=&quot;../lib/jsocka.js&quot;&gt;&lt;/script&gt;
+		&lt;!-- &lt;script src=&quot;spec.grammar-less.js&quot;&gt;&lt;/script&gt; --&gt;
 		&lt;script&gt;
-		  function runSuites() {
-		    JSpec
-		      .exec('spec.stubbing.js')
-		      .run()
-		      .report()
-		  }
+			function runSuites() {
+				JSpec
+        .exec('spec.stubbing.js')
+				.run()
+				.report()
+			}
 		&lt;/script&gt;
 	&lt;/head&gt;
 	&lt;body class=&quot;jspec&quot; onLoad=&quot;runSuites();&quot;&gt;
 		&lt;div id=&quot;jspec-top&quot;&gt;&lt;h2 id=&quot;jspec-title&quot;&gt;JSpec &lt;em&gt;&lt;script&gt;document.write(JSpec.version)&lt;/script&gt;&lt;/em&gt;&lt;/h2&gt;&lt;/div&gt;
-		&lt;div id=&quot;jspec&quot;&gt;&lt;/div&gt;
+		&lt;div id=&quot;jspec&quot;&gt;&lt;div class=&quot;loading&quot;&gt;&lt;/div&gt;&lt;/div&gt;
 		&lt;div id=&quot;jspec-bottom&quot;&gt;&lt;/div&gt;
 	&lt;/body&gt;
 &lt;/html&gt;</diff>
      <filename>spec/suite.html</filename>
    </modified>
  </modified>
  <removed type="array">
    <removed>
      <filename>spec/lib/images/bg.png</filename>
    </removed>
    <removed>
      <filename>spec/lib/images/hr.png</filename>
    </removed>
    <removed>
      <filename>spec/lib/images/loading.gif</filename>
    </removed>
    <removed>
      <filename>spec/lib/images/sprites.bg.png</filename>
    </removed>
    <removed>
      <filename>spec/lib/images/sprites.png</filename>
    </removed>
    <removed>
      <filename>spec/lib/images/vr.png</filename>
    </removed>
    <removed>
      <filename>spec/lib/jspec.css</filename>
    </removed>
    <removed>
      <filename>spec/lib/jspec.jquery.js</filename>
    </removed>
    <removed>
      <filename>spec/lib/jspec.js</filename>
    </removed>
  </removed>
  <parents type="array">
    <parent>
      <id>946685f01804ae2dbe0cb747a7db20b673e9607b</id>
    </parent>
  </parents>
  <author>
    <name>Kevin Gisi</name>
    <email>kevin.gisi@gmail.com</email>
  </author>
  <url>http://github.com/gisikw/jsocka/commit/aca2162e88c78c18dc2cf66dfb5bc7b8a98dec2e</url>
  <id>aca2162e88c78c18dc2cf66dfb5bc7b8a98dec2e</id>
  <committed-date>2009-08-03T22:46:15-07:00</committed-date>
  <authored-date>2009-08-03T22:46:15-07:00</authored-date>
  <message>Completed JSpec integration module</message>
  <tree>1642dc6b21d99ff803112b8d5acf48f333ca4487</tree>
  <committer>
    <name>Kevin Gisi</name>
    <email>kevin.gisi@gmail.com</email>
  </committer>
</commit>
