I've seen that. I'll go through the tests again. Thanks marios. On Tue, Nov 27, 2012 at 10:44 AM, [email protected] <[email protected]>wrote:
> just one comment (I only noticed this after the broken build > -https://travis-ci.org/mifo/deltacloud/builds/3376824 ): > > On 24/11/12 19:06, [email protected] wrote: > > From: njerichelimo <[email protected]> > > > > --- > > server/tests/drivers/mock/buckets_test.rb | 18 ++++++++++++++++++ > > 1 file changed, 18 insertions(+) > > create mode 100644 server/tests/drivers/mock/buckets_test.rb > > > > diff --git a/server/tests/drivers/mock/buckets_test.rb > b/server/tests/drivers/mock/buckets_test.rb > > new file mode 100644 > > index 0000000..5b46aac > > --- /dev/null > > +++ b/server/tests/drivers/mock/buckets_test.rb > > @@ -0,0 +1,18 @@ > > +require 'minitest/autorun' > > + > > +require_relative File.join('..', '..', '..', 'lib', 'deltacloud', > 'api.rb') > > ^^^ you don't need to do this here - because you are requiring > 'common.rb' below - which in turn pulls in 'test_helper' that includes > the /lib/deltacloud/api.rb > > The build broke because for ruby 1.8.7 we need to include > require_relative - you'll notice this at the top of the other tests in > mock driver directory: > > require 'rubygems' > require 'require_relative' if RUBY_VERSION < '1.9' > > I just fixed these nits and pushed a commit - just fyi if you plan to > add to these tests > > > thanks again, marios > > > > > +require_relative 'common.rb' > > + > > +describe 'MockDriver Buckets' do > > + > > + before do > > + @driver = Deltacloud::new(:mock, :user => 'mockuser', :password => > 'mockpassword') > > + end > > + > > + it 'must throw error when wrong credentials for buckets' do > > + Proc.new do > > + @driver.backend.buckets(OpenStruct.new(:user => 'unknown', > :password => 'wrong')) > > + end.must_raise Deltacloud::Exceptions::AuthenticationFailure, > 'Authentication Failure' > > + end > > + > > +end > > > > -- { mail : [ email : "[email protected]" ], social : [ { twitter : "@NjeriChelimo" } , {facebook : "Njeri Chelimo" } ], code : [ { github : "Njeri Chelimo"}, { bitbucket : "nchelimo" } ], skype : "martha.chumo" }
