Sha256: da0d98dcf5181e384823573acee83ea09815710c37c032094d4739a742ac03fd
Contents?: true
Size: 500 Bytes
Versions: 10
Compression:
Stored size: 500 Bytes
Contents
# coding: utf-8 require 'spec_helper' RSpec.describe TTY::Table::Row, '#data' do let(:object) { described_class.new data, header } let(:data) { ['a'] } subject { object.to_hash } context 'without attributes' do let(:header) { nil } it { is_expected.to be_instance_of(Hash) } it { is_expected.to eql(0 => 'a') } end context 'with attributes' do let(:header) { [:id] } it { is_expected.to be_instance_of(Hash) } it { is_expected.to eql(id: 'a') } end end
Version data entries
10 entries across 10 versions & 1 rubygems