Sha256: e225ec5bc9db729c4436abfe020d51cd5791b1a3149725b8534324b17ac03f42
Contents?: true
Size: 774 Bytes
Versions: 6
Compression:
Stored size: 774 Bytes
Contents
require "spec_helper" describe UniformNotifier::JavascriptConsole do it "should not notify message" do UniformNotifier::JavascriptConsole.inline_notify(:title => "javascript console!").should be_nil end it "should notify message" do UniformNotifier.console = true UniformNotifier::JavascriptConsole.inline_notify(:title => "javascript console!").should == <<-CODE <script type="text/javascript">/*<![CDATA[*/ if (typeof(console) !== 'undefined' && console.log) { if (console.groupCollapsed && console.groupEnd) { console.groupCollapsed(#{"Uniform Notifier".inspect}); console.log(#{"javascript console!".inspect}); console.groupEnd(); } else { console.log(#{"javascript console!".inspect}); } } /*]]>*/</script> CODE end end
Version data entries
6 entries across 6 versions & 1 rubygems