0
0
Fork 0

Fix little things

This commit is contained in:
Stormwind 2015-05-05 21:42:05 +02:00
parent ba6c12ad89
commit 496e96be91
3 changed files with 5 additions and 5 deletions

View File

@ -51,8 +51,6 @@ module Rubella
# Returns the current length of the storage. # Returns the current length of the storage.
# (How many datasets it holds.) # (How many datasets it holds.)
# #
# TODO Throw an error, if data has different lengths
#
# @return Integer length # @return Integer length
# #
def length def length
@ -62,6 +60,8 @@ module Rubella
# Returns the length of a dataset. # Returns the length of a dataset.
# Will return 0, if no datasets in storage. # Will return 0, if no datasets in storage.
# #
# TODO Throw an error, if data has different lengths
#
# @return Integer length of one dataset # @return Integer length of one dataset
# #
def dataset_length def dataset_length

View File

@ -8,4 +8,4 @@ describe Rubella::Input::Base, '.data' do
expect(input.data).to eq([3, 4, 5]) expect(input.data).to eq([3, 4, 5])
end end
end end

View File

@ -3,10 +3,10 @@ require 'spec_helper'
describe Rubella::Input::Base, '.each' do describe Rubella::Input::Base, '.each' do
it "passes the data through the given block" do it "passes the data through the given block" do
storage = Rubella::Input::Base.new [3, 4, 5] input = Rubella::Input::Base.new [3, 4, 5]
sum = 0 sum = 0
storage.each do |value| input.each do |value|
sum = sum + value sum = sum + value
end end