Sha256: 4970907c2f972b598781fb9f97e261b31ff88ca670bd24ff25296df6178b23b3
Contents?: true
Size: 1.22 KB
Versions: 14
Compression:
Stored size: 1.22 KB
Contents
# -*- encoding : utf-8 -*- describe Card::Set::Type::CoffeeScript do let(:coffee) { 'alert "Hi" ' } let(:compressed_coffee) { '(function(){alert("Hi")}).call(this);' } let(:changed_coffee) { 'alert "Hello" ' } let(:compressed_changed_coffee) { '(function(){alert("Hello")}).call(this);' } it_should_behave_like 'content machine', that_produces_js do let(:machine_card) { Card.gimme! "test coffeescript", type: Card::CoffeeScriptID, content: coffee} let(:card_content) do { in: coffee, out: compressed_coffee, changed_in: changed_coffee, changed_out: compressed_changed_coffee } end end it_behaves_like "machine input" do let(:create_machine_input_card) { Card.gimme! "test coffeescript", type: :coffee_script, content: coffee } let(:create_another_machine_input_card) { Card.gimme! "more coffee", type: :coffee_script, content: coffee } let(:create_machine_card) { Card.gimme! "script with coffee+*script", type: :pointer } let(:card_content) do { in: coffee, out: compressed_coffee, changed_in: changed_coffee, changed_out: compressed_changed_coffee } end end end
Version data entries
14 entries across 14 versions & 1 rubygems