Sha256: a84cf1b7f59a816ad96b324ba068e2b8aab079d4d6967239b1ff4235444ea899

Contents?: true

Size: 651 Bytes

Versions: 3

Compression:

Stored size: 651 Bytes

Contents

require File.join(File.dirname(__FILE__), 'test_helper.rb')

class ExegesisServerTest < Test::Unit::TestCase

  before(:all) do
    @db = 'http://localhost:5984/exegesis-test'
    RestClient.delete @db rescue nil
    RestClient.delete "#{@db}-2" rescue nil
    RestClient.put @db, ''
    
    @server = Exegesis::Server.new('http://localhost:5984')
  end
  
  context "listing databases" do
    expect { @server.databases.include?('exegesis-test').will == true }
  end
  
  context "creating a database" do
    before do
      @response = @server.create_database('exegesis-test-2')
    end
    
    expect { @response['ok'].will == true }
  end
  
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
mattly-exegesis-0.2.0 test/server_test.rb
mattly-exegesis-0.2.1 test/server_test.rb
mattly-exegesis-0.2.2 test/server_test.rb