Sha256: 38c39e0a313881fbe90fb825f07378c086a19d22a494d85e846bb3f2fa3bfdbb

Contents?: true

Size: 659 Bytes

Versions: 6

Compression:

Stored size: 659 Bytes

Contents

require 'rspectacular'
require 'ruby-progressbar/format/molecule'

class           ProgressBar
module          Format
RSpec.describe  Molecule do
  it 'sets the key when initialized' do
    molecule = Molecule.new('t')

    expect(molecule.key).to eql 't'
  end

  it 'sets the method name when initialized' do
    molecule = Molecule.new('t')

    expect(molecule.method_name).to eql [:title_comp, :title]
  end

  it 'can retrieve the full key for itself' do
    molecule = Molecule.new('t')

    expect(molecule.full_key).to eql '%t'
  end

  it 'can determine if it is a bar molecule' do
    expect(Molecule.new('B')).to be_bar_molecule
  end
end
end
end

Version data entries

6 entries across 6 versions & 3 rubygems

Version Path
fluent-plugin-detect-memb-exceptions-0.0.2 vendor/bundle/ruby/2.0.0/gems/ruby-progressbar-1.8.1/spec/ruby-progressbar/format/molecule_spec.rb
fluent-plugin-detect-memb-exceptions-0.0.1 vendor/bundle/ruby/2.0.0/gems/ruby-progressbar-1.8.1/spec/ruby-progressbar/format/molecule_spec.rb
progressbar-1.8.2 spec/ruby-progressbar/format/molecule_spec.rb
progressbar-1.8.1 spec/ruby-progressbar/format/molecule_spec.rb
ruby-progressbar-1.8.1 spec/ruby-progressbar/format/molecule_spec.rb
ruby-progressbar-1.8.0 spec/ruby-progressbar/format/molecule_spec.rb