Sha256: 520e9ed2732c03d8dd80b7435ccd4ccc43206b5a47b8b02c8e04ec68ab1cb39b
Contents?: true
Size: 529 Bytes
Versions: 7
Compression:
Stored size: 529 Bytes
Contents
require 'spec_helper' describe Locomotive::Steam::Liquid::Tags::GoogleAnalytics do let(:source) { "{% google_analytics 42 %}" } subject { render_template(source) } it { is_expected.to include %{<script async src="https://www.googletagmanager.com/gtag/js?id=42"></script>} } it { is_expected.to include "gtag('config', '42');" } describe 'raises an error if the syntax is incorrect' do let(:source) { '{% google_analytics %}' } it { expect { subject }.to raise_exception(::Liquid::SyntaxError) } end end
Version data entries
7 entries across 7 versions & 1 rubygems