Sha256: c4b92c6018f2547a66d5bf8b48aee2aae2f6b2979f224ea46d486da97ae3782b
Contents?: true
Size: 765 Bytes
Versions: 40
Compression:
Stored size: 765 Bytes
Contents
require 'lib/spec_helper' require 'opal/builder_processors' describe Opal::Builder::RubyProcessor do it 'compiles ruby to js' do processor = described_class.new('puts 5', '-e') expect(processor.to_s).to include('$puts(5)') end describe ':requirable option' do it 'is respected' do processor = described_class.new('puts 5', '-e', requirable: true) expect(processor.to_s).to include('Opal.modules[') end it 'defaults to "false"' do processor = described_class.new('puts 5', '-e') expect(processor.to_s).not_to include('Opal.modules[') end end it 'fills required_trees' do processor = described_class.new('require_tree "./pippo"', '-e') expect(processor.required_trees).to eq(['pippo']) end end
Version data entries
40 entries across 40 versions & 3 rubygems