Sha256: f6599ef2eb72e11afa04112030b0cf904daedee6a4e2eec3fafc9c4c68e88ebe
Contents?: true
Size: 947 Bytes
Versions: 4
Compression:
Stored size: 947 Bytes
Contents
require 'spec_helper' describe Fit::File::Definition do context "given a sample definition message" do describe ".read" do subject do described_class.read example_file('record/message/definition') end its(:architecture) { should == 0 } its(:global_message_number) { should == 0 } its(:field_count) { should == 6 } it { expect(subject.fields.size).to eq(subject.field_count) } its(:record_type) { should == :definition } it 'returns the real type for fields' do expect(subject.fields[0].real_type).to be == :uint32z expect(subject.fields[1].real_type).to be == :date_time expect(subject.fields[2].real_type).to be == :manufacturer expect(subject.fields[3].real_type).to be == :uint16 # product expect(subject.fields[4].real_type).to be == :uint16 # number expect(subject.fields[5].real_type).to be == :file end end end end
Version data entries
4 entries across 4 versions & 2 rubygems
Version | Path |
---|---|
fit-parser-0.0.2 | spec/file/definition_spec.rb |
fit-parser-0.0.1 | spec/file/definition_spec.rb |
fit_parser-0.0.2 | spec/file/definition_spec.rb |
fit_parser-0.0.1 | spec/file/definition_spec.rb |