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

View File

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

View File

@ -3,10 +3,10 @@ require 'spec_helper'
describe Rubella::Input::Base, '.each' 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
storage.each do |value|
input.each do |value|
sum = sum + value
end