Sha256: 20e6998853cb9ea9edcdb7b48f8239c09261d2ba98c2b6047d85150dc60f551b
Contents?: true
Size: 380 Bytes
Versions: 45
Compression:
Stored size: 380 Bytes
Contents
require 'generator/exercise_case' class DominoesCase < Generator::ExerciseCase def name 'test_%s' % description.gsub("can't", 'can not').gsub(/[= -]+/, '_') end def workload <<-WL.chomp input_dominoes = #{input} output_chain = Dominoes.chain(input_dominoes) #{can_chain ? 'assert' : 'refute' }_correct_chain(input_dominoes, output_chain) WL end end
Version data entries
45 entries across 45 versions & 1 rubygems