Sha256: 9a0732392e7ca9b13c4da8fdfdf1224dc2bf7eb6cb9bfd3ff928caf47adfceba
Contents?: true
Size: 954 Bytes
Versions: 2
Compression:
Stored size: 954 Bytes
Contents
# frozen_string_literal: true require 'spec_helper' describe Symbol do describe '#camelize' do it { expect(:sym.camelize).to be_kind_of(described_class) } context 'when called with upper option' do it 'camelize the symbol' do expect(:underscore_sym.camelize(:upper)).to eq(:UnderscoreSym) end end context 'when called with lower option' do it 'camelize the symbol without captalization' do expect(:underscore_sym.camelize(:lower)).to eq(:underscoreSym) end end context 'when called without option' do it 'camelize the symbol' do expect(:underscore_sym.camelize).to eq(:UnderscoreSym) end end end describe '#underscore' do it { expect(:symBol.underscore).to be_kind_of(described_class) } context 'when called with upper option' do it 'underscore the symbol' do expect(:symBol.underscore).to eq(:sym_bol) end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
darthjee-core_ext-2.0.0 | spec/lib/symbol_spec.rb |
darthjee-core_ext-1.7.4 | spec/lib/symbol_spec.rb |