Sha256: c08f5622ce4877e5b49388ed5e85e9d75713b16c3269d350684c16c7b7aec5fd
Contents?: true
Size: 670 Bytes
Versions: 4
Compression:
Stored size: 670 Bytes
Contents
# Encoding: utf-8 require 'spec_helper' describe 'mod leader' do let(:client) do Etcd.client end it 'should allow setting a key value with ttl' do client.set_leader('/db_master1', 'db01', 10) expect(client.get_leader('/db_master1')).to eq('db01') end it 'should allow deleting key with value' do client.set_leader('/db_master4', 'db04', 10) expect do client.delete_leader('/db_master4', 'db04') end.to_not raise_error end it 'should not allow deleting key without value' do client.set_leader('/db_master5', 'db05', 10) expect do client.delete_leader('/db_master5', 'db04') end.to raise_error end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
etcd-0.2.2 | spec/etcd/leader_spec.rb |
etcd-0.2.1 | spec/etcd/leader_spec.rb |
etcd-0.2.0.beta.1 | spec/etcd/leader_spec.rb |
etcd-0.2.0.alpha | spec/etcd/leader_spec.rb |