Add some basic test cases to make sure that at least the library is getting loaded

This commit is contained in:
R. Tyler Croy 2014-08-28 16:16:00 -07:00
parent fbdf9b6055
commit 96ff104061
3 changed files with 29 additions and 0 deletions

11
spec/consumer_spec.rb Normal file
View File

@ -0,0 +1,11 @@
require 'spec_helper'
describe Hermann::Consumer do
subject(:consumer) { described_class.new(topic, brokers, partition) }
let(:topic) { 'rspec' }
let(:brokers) { 'localhost:1337' }
let(:partition) { 1 }
it { should respond_to :consume }
end

6
spec/hermann_spec.rb Normal file
View File

@ -0,0 +1,6 @@
require 'spec_helper'
describe Hermann do
it { should be_instance_of Module }
end

12
spec/producer_spec.rb Normal file
View File

@ -0,0 +1,12 @@
require 'spec_helper'
describe Hermann::Producer do
subject(:producer) { described_class.new(topic, brokers) }
let(:topic) { 'rspec' }
let(:brokers) { 'localhost:1337' }
describe '#push' do
it { should respond_to :push }
end
end