Sha256: eaabfcf6cb192daff458b56b242ae2c5f0378d4f141fc71a88979ded36005f0f
Contents?: true
Size: 1.06 KB
Versions: 10
Compression:
Stored size: 1.06 KB
Contents
require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') describe "Analytical::Modules::Adroll" do before(:each) do @parent = mock('api', :options=>{:Adroll=>{:key=>'abc'}}) end describe 'on initialize' do it 'should set the command_location' do a = Analytical::Modules::Adroll.new :parent=>@parent, :key=>'abc' a.tracking_command_location.should == :body_append end it 'should set the options' do a = Analytical::Modules::Adroll.new :parent=>@parent, :key=>'abc' a.options.should == {:key=>'abc', :parent=>@parent} end end describe '#init_javascript' do it 'should return the init javascript' do @api = Analytical::Modules::Adroll.new :parent=>@parent, :adv_id=>'abcdef', :pix_id=>'123456' @api.init_javascript(:head_prepend).should == '' @api.init_javascript(:head_append).should == '' @api.init_javascript(:body_append).should =~ /abcdef/ @api.init_javascript(:body_append).should =~ /123456/ @api.init_javascript(:body_append).should =~ /adroll\.com/ end end end
Version data entries
10 entries across 10 versions & 2 rubygems