Sha256: 28fd5f79a5b3ab8653bd6585b1f55382f6100f0fbe8fe8ed735e2745407f1639

Contents?: true

Size: 541 Bytes

Versions: 16

Compression:

Stored size: 541 Bytes

Contents

require 'spec_helper'

require 'mspire/isotope/aa'

describe 'accessing an amino acid atom count' do
  before do
    @alanine = {:c=>3, :h=>5, :o=>1, :n=>1, :s=>0, :p=>0, :se=>0}
  end

  it 'residue can be accessed with a symbol' do
    hash = Mspire::Isotope::AA::FORMULAS[:A]
    [:c, :h, :o, :n, :s].each {|key| hash[key].should == @alanine[key] }
  end
    
  it 'residue can be accessed with a string' do
    hash = Mspire::Isotope::AA::FORMULAS['A']
    [:c, :h, :o, :n, :s].each {|key| hash[key].should == @alanine[key] }
  end

end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
mspire-0.8.7 spec/mspire/isotope/aa_spec.rb
mspire-0.8.6.2 spec/mspire/isotope/aa_spec.rb
mspire-0.8.6.1 spec/mspire/isotope/aa_spec.rb
mspire-0.8.6 spec/mspire/isotope/aa_spec.rb
mspire-0.8.5 spec/mspire/isotope/aa_spec.rb
mspire-0.8.4 spec/mspire/isotope/aa_spec.rb
mspire-0.8.3 spec/mspire/isotope/aa_spec.rb
mspire-0.8.2 spec/mspire/isotope/aa_spec.rb
mspire-0.8.1 spec/mspire/isotope/aa_spec.rb
mspire-0.8.0 spec/mspire/isotope/aa_spec.rb
mspire-0.7.18 spec/mspire/isotope/aa_spec.rb
mspire-0.7.17 spec/mspire/isotope/aa_spec.rb
mspire-0.7.13 spec/mspire/isotope/aa_spec.rb
mspire-0.7.12 spec/mspire/isotope/aa_spec.rb
mspire-0.7.11 spec/mspire/isotope/aa_spec.rb
mspire-0.7.10 spec/mspire/isotope/aa_spec.rb