Sha256: b0cec071b2eb8df0737f6b0e7f8b4ec21abdbc9fc665e1dcc2837c475af182b8

Contents?: true

Size: 571 Bytes

Versions: 233

Compression:

Stored size: 571 Bytes

Contents

require 'generator/exercise_case'

class TwoBucketCase < Generator::ExerciseCase
  def name
    "test_bucket_one_size_#{bucket_one}_bucket_two_"\
    "size_#{bucket_two}_goal_#{goal}_start_with_bucket_#{start_bucket}"
  end

  def workload
    "two_bucket = #{self.do}
    assert_equal #{expected['moves']}, two_bucket.moves
    assert_equal '#{expected['goal_bucket']}', two_bucket.goal_bucket
    assert_equal #{expected['other_bucket']}, two_bucket.other_bucket"
  end

  def do
    "TwoBucket.new(#{bucket_one}, #{bucket_two}, #{goal}, '#{start_bucket}')"
  end

end

Version data entries

233 entries across 233 versions & 1 rubygems

Version Path
trackler-2.2.1.180 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.179 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.178 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.177 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.176 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.175 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.174 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.173 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.172 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.171 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.170 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.169 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.167 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.166 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.165 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.164 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.163 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.162 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.161 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb
trackler-2.2.1.160 tracks/ruby/exercises/two-bucket/.meta/generator/two_bucket_case.rb