Sha256: e479b506fe8ca1e37ef676457583fa66b11d379f7da67dea67238851404d0449

Contents?: true

Size: 1.07 KB

Versions: 1

Compression:

Stored size: 1.07 KB

Contents

require 'spec_helper'

describe Symbol do
  describe '#compose' do
    subject { :to_s }

    it_should_behave_like 'composable'
  end

  describe '#with_args' do
    subject {:delete }

    it_should_behave_like 'with_args' do
      let(:x) { 'foobar' }
      let(:y) { 'o'  }
      let(:z) { 'a'}
    end
  end

  describe '#flip' do
    context 'arity = 1' do
      subject { :to_s }

      it_should_behave_like 'flip(arity=1)'
    end

    context 'varargs' do
      subject {:product }

      it_should_behave_like 'flip(varargs)' do
        let(:x) { [:bar] }
        let(:y) { [:foo] }
      end
    end
  end

  describe '#curry' do
    subject { :product }

    it_should_behave_like 'curry(varargs)' do
      let(:x) { [:bar] }
      let(:y) { [:foo] }
    end
  end

  describe '#call' do
    subject { :to_s }

    it_should_behave_like 'call'
  end

  describe 'ailases' do
    subject { :to_s }

    it_should_behave_like 'aliases'

    it_should_behave_like 'aliases(varargs)' do
      subject { :product }
      let(:x) { [:bar] }
      let(:y) { [:foo] }
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
lambda_driver-1.0.0 spec/symbol_spec.rb