Sha256: 7e7f3cf4c4929af4a39c11959e0b6463cce47012bd029bac5e6046614e1db5d9
Contents?: true
Size: 1.07 KB
Versions: 1
Compression:
Stored size: 1.07 KB
Contents
$:<< "lib/" require 'etcd' require 'uuid' ETCD_BIN = ENV['ETCD_BIN'] || './etcd/etcd' require 'functional_spec_helpers' require 'functional/lock_spec' require 'functional/read_only_client_spec' require 'functional/test_and_set_spec' require 'functional/watch_spec' include Etcd::FunctionalSpec::Helpers describe "Functional Test Suite" do before(:all) do start_etcd_servers end let(:etcd_servers) do (1..5).map{|n| "http://127.0.0.1:700#{n}"} end after(:all) do stop_etcd_servers end let(:client) do Etcd.client end let(:read_only_client) do Etcd.client(:allow_redirect=>false, :port=> 4004) end include_examples "read only client" include_examples "lock" include_examples "test_and_set" include_examples "watch" it "#set/#get" do key = random_key value = uuid.generate client.set(key, value) expect(client.get(key).value).to eq(value) end it "#leader" do expect(etcd_servers).to include(client.leader) end it "#machines" do expect(client.machines).to include('http://127.0.0.1:4001') end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
etcd-0.0.6 | spec/functional/client_spec.rb |