Sha256: cbc46d5e44420b16683b5d6599dd25923c014a21283e5e56a1c369f86a6d7910

Contents?: true

Size: 555 Bytes

Versions: 1

Compression:

Stored size: 555 Bytes

Contents

# vim: noai:ts=3:sts=3:et:sw=3
# Actor spec
require 'baltix/spec'

module Baltix::Actor::Spec
   class << self
      def context_kind
         Baltix::Space
      end

      # +apply_to+ generates spec according to the provided setup
      #
      def apply_to space, template = nil
         spec = Baltix::Spec.find(space.spec_type)

         rendered = spec.render(space, template)

         if space.options.output_file
            File.open(space.options.output_file, "w") { |f| f.puts(rendered) }
         end

         rendered
      end
   end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
baltix-0.1.1 lib/baltix/actor/spec.rb