Sha256: 6ef5a10c6d736cc765800ed096ac54b7f7da3583b5ec65afb639e029b3bf9dfc

Contents?: true

Size: 907 Bytes

Versions: 30

Compression:

Stored size: 907 Bytes

Contents

require 'spec_helper'
require 'compiler'

module Libv8::Compiler
  describe AppleLLVM do
    subject { AppleLLVM.new 'c++' }

    describe '#name' do
      it 'returns Apple LLVM' do
        expect(subject.name).to eq 'Apple LLVM'
      end
    end

    describe '#version' do
      it 'returns the version of the compiler' do
        stub_as_available 'c++', :apple_llvm, '4.20'
        expect(subject.version).to eq '4.20'
      end
    end

    describe '#compatible?' do
      context 'when Apple LLVM\'s version is >= 4.3' do
        it 'returns true' do
          stub_as_available 'c++', :apple_llvm, '4.20'
          expect(subject).to be_compatible
        end
      end

      context 'when Apple LLVM\'s version is < 4.3' do
        it 'returns false' do
          stub_as_available 'c++', :apple_llvm, '4.2'
          expect(subject).to_not be_compatible
        end
      end
    end
  end
end

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
libv8-6.3.292.48.1 spec/compiler/apple_llvm_spec.rb
libv8-6.3.292.48.0 spec/compiler/apple_llvm_spec.rb
libv8-6.3.292.48.0beta2 spec/compiler/apple_llvm_spec.rb
libv8-6.3.292.48.0beta1 spec/compiler/apple_llvm_spec.rb
libv8-6.2.414.42.1 spec/compiler/apple_llvm_spec.rb
libv8-6.2.414.42.0 spec/compiler/apple_llvm_spec.rb
libv8-6.2.414.42.0beta1 spec/compiler/apple_llvm_spec.rb
libv8-6.0.286.54.3 spec/compiler/apple_llvm_spec.rb
libv8-6.0.286.54.2 spec/compiler/apple_llvm_spec.rb
libv8-6.0.286.54.1 spec/compiler/apple_llvm_spec.rb
libv8-6.0.286.54.0 spec/compiler/apple_llvm_spec.rb
libv8-6.0.286.54.0beta2 spec/compiler/apple_llvm_spec.rb
libv8-6.0.286.54.0beta1 spec/compiler/apple_llvm_spec.rb
libv8-6.0.286.44.0beta1 spec/compiler/apple_llvm_spec.rb
libv8-5.9.211.38.1 spec/compiler/apple_llvm_spec.rb
libv8-5.9.211.38.0 spec/compiler/apple_llvm_spec.rb
libv8-5.9.211.38.0beta0 spec/compiler/apple_llvm_spec.rb
libv8-5.7.492.65.1 spec/compiler/apple_llvm_spec.rb
libv8-5.7.492.65.0 spec/compiler/apple_llvm_spec.rb
libv8-5.7.492.65.0beta1 spec/compiler/apple_llvm_spec.rb