Sha256: e533a8932995e049d846d546755c8cab2ff7d0ca4d58dadec0092d101ba9d770

Contents?: true

Size: 473 Bytes

Versions: 13

Compression:

Stored size: 473 Bytes

Contents

module CukeModeler

  # A mix-in module containing methods used by models that represent an element that has steps.

  module Stepped


    # The step models contained by this model
    attr_accessor :steps


    private


    def steps_output_string
      steps.collect { |step| indented_step_text(step) }.join("\n")
    end

    def indented_step_text(step)
      step.to_s.split("\n").collect { |line| "  #{line}" }.join("\n")
    end

  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
cuke_modeler-1.5.1 lib/cuke_modeler/stepped.rb
cuke_modeler-1.5.0 lib/cuke_modeler/stepped.rb
cuke_modeler-1.4.0 lib/cuke_modeler/stepped.rb
cuke_modeler-1.3.0 lib/cuke_modeler/stepped.rb
cuke_modeler-1.2.1 lib/cuke_modeler/stepped.rb
cuke_modeler-1.2.0 lib/cuke_modeler/stepped.rb
cuke_modeler-1.1.1 lib/cuke_modeler/stepped.rb
cuke_modeler-1.1.0 lib/cuke_modeler/stepped.rb
cuke_modeler-1.0.4 lib/cuke_modeler/stepped.rb
cuke_modeler-1.0.3 lib/cuke_modeler/stepped.rb
cuke_modeler-1.0.2 lib/cuke_modeler/stepped.rb
cuke_modeler-1.0.1 lib/cuke_modeler/stepped.rb
cuke_modeler-1.0.0 lib/cuke_modeler/stepped.rb