Sha256: 2d4e6745ff7a8d22aed348c17aa73998c33876f8a64ca7448bbba5c6bb076e4d

Contents?: true

Size: 1.82 KB

Versions: 1

Compression:

Stored size: 1.82 KB

Contents

require 'spec_helper'

describe Bezebe::CVS do
    describe "when using a known repository (W3)" do

        describe "with correct credentials" do
            it "should work"
        end

        describe "with wrong credentials" do
            it "shouldn't work"
        end
        
        before do
            #::Bezebe::CVS.stub!(:puts)
            #::Bezebe::CVS.stub!(:p)
            #stub!(:puts)
            #stub!(:p)
            @client1 = ::Bezebe::CVS::CVSClient.new
            @client1.connect FactoryGirl.attributes_for(:connection_details)
        end

        it 'should be able to checkout a single file' do
            a = @client1.checkout "/tmp/", "w3c/test/foo"
        end

        it 'should be able to checkout two files' do
            b = @client1.checkout "/tmp/", [ "w3c/test/foo", "w3c/test/bar" ]
        end

        it 'should have issues to checkout a known file and an unkown one' do
            b = @client1.checkout "/tmp/", [ "w3c/test/foo", "w3c/test/somethingthatisnotthere" ]
        end

        it 'should have issues to checkout a known file and an wrong module one' do
            b = @client1.checkout "/tmp/", [ "w3c/test/foo", "somefakeroot/w3c/test/somethingthatisnotthere" ]
        end

        it 'should have issues to checkout a known file and an unkown one (again)' do
            b = @client1.checkout "/tmp/", [ "w3c/test/foo", "/w3c/test/somethingthatisnotthere" ]
        end

        it 'should have issues to checkout a known file and an wrong module one (again)' do
            b = @client1.checkout "/tmp/", [ "w3c/test/foo", "/somefakeroot/w3c/test/somethingthatisnotthere" ]
        end

        it 'should be fast getting a folder' do
            1.times do
                FileUtils.rm_rf "/tmp/w3c/";
                @client1.checkout "/tmp/", "w3c"
            end
        end

    end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bezebe-cvs-0.0.1 spec/checkout_spec.rb