We got nominated! Help us out and vote for GitHub as Best Bootstrapped Startup of 2008. (You can vote once a day.) [ hide ]

public
Rubygem
Description: A server that conveniently serves screw unit specs, implementation javascript, and other assets such as css.
Homepage: http://github.com/btakita/screw-unit-server
Clone URL: git://github.com/btakita/screw-unit-server.git
Functional spec passes.
Brian Takita (author)
Wed Aug 27 16:09:10 -0700 2008
commit  78288e12487bbb3c810c6a826e19a4210ba0b04d
tree    36195fc8235adfc603b71bf882786864c4d53da5
parent  f0de420dc69d069e6c172fce6698857a29d18a93
...
1
2
3
 
 
 
 
 
 
 
 
 
 
 
4
5
6
 
7
8
9
10
11
12
 
 
13
14
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
 
16
17
18
19
20
 
 
21
22
23
24
25
0
@@ -1,14 +1,25 @@
0
 require File.expand_path("#{File.dirname(__FILE__)}/functional_spec_helper")
0
 
0
 describe "ScrewUnit" do
0
+ attr_reader :stdout, :request
0
+ before do
0
+ @stdout = StringIO.new
0
+ ScrewUnit::Client.const_set(:STDOUT, stdout)
0
+ @request = "http request"
0
+ end
0
+
0
+ after do
0
+ ScrewUnit::Client.__send__(:remove_const, :STDOUT)
0
+ end
0
+
0
   it "runs a full passing Suite" do
0
- mock(ScrewUnit::Client).puts("SUCCESS")
0
     ScrewUnit::Client.run(:spec_url => "#{root_url}/specs/foo/passing_spec")
0
+ stdout.string.strip.should == "SUCCESS"
0
   end
0
 
0
   it "runs a full failing Suite" do
0
- mock(ScrewUnit::Client).puts("FAILURE")
0
- mock(ScrewUnit::Client).puts('expected true to equal false')
0
     ScrewUnit::Client.run(:spec_url => "#{root_url}/specs/foo/failing_spec")
0
+ stdout.string.strip.should include("FAILURE")
0
+ stdout.string.strip.should include("expected true to equal false")
0
   end
0
 end

Comments

    No one has commented yet.