Sha256: ab20809648997370ba2603301246259e9315ac82862a7682cd1df3591d9d78c8

Contents?: true

Size: 719 Bytes

Versions: 23

Compression:

Stored size: 719 Bytes

Contents

require 'spec_helper'

describe Vx::Builder::Script::Scala do
  let(:app)    { ->(env) { env } }
  let(:script) { described_class.new app }
  let(:source) { create :source, name: "scala.yml" }
  let(:env)    { create :env, source: source }
  let(:run)    { script.call env }
  subject { run }

  it { should eq env }

  context "run it" do
    subject { env }

    context "should be success" do
      before { run }
      its(:announce)           { should_not be_empty }
      its(:cached_directories) { should eq %w{ ~/.sbt ~/.ivy2 } }
    end

    context "when script is empty" do
      before do
        env.source.script.clear
        run
      end
      its(:script) { should_not be_empty }
    end


  end

end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
vx-builder-0.0.21 spec/lib/builder/script/scala_spec.rb
vx-builder-0.0.20 spec/lib/builder/script/scala_spec.rb
vx-builder-0.0.19 spec/lib/builder/script/scala_spec.rb