2014-01-17 19:55:26 +00:00
|
|
|
require 'spec_helper'
|
|
|
|
|
|
2014-01-21 14:51:03 +00:00
|
|
|
describe IcecastTemplate do
|
2014-01-17 19:55:26 +00:00
|
|
|
|
|
|
|
|
let(:template) { template = FactoryGirl.create(:icecast_template_minimal) }
|
|
|
|
|
|
|
|
|
|
it "save" do
|
|
|
|
|
template.errors.any?.should be_false
|
|
|
|
|
end
|
2014-01-21 14:51:03 +00:00
|
|
|
|
|
|
|
|
describe "poke configs" do
|
|
|
|
|
let(:server) { a = FactoryGirl.create(:icecast_server_with_overrides); a.config_updated; IcecastServer.find(a.id) }
|
|
|
|
|
|
|
|
|
|
it "success via template" do
|
|
|
|
|
server.template.save!
|
|
|
|
|
server.reload
|
|
|
|
|
server.config_changed.should == 1
|
|
|
|
|
end
|
|
|
|
|
end
|
2014-01-17 19:55:26 +00:00
|
|
|
end
|