Sha256: 2dd1f9406ebd9c5e8ba105c92da0e3420d7430a15eef63072b148ba24e8b5664

Contents?: true

Size: 670 Bytes

Versions: 3

Compression:

Stored size: 670 Bytes

Contents

require File.join(File.expand_path('../../test_helper', __FILE__))
require 'digest/sha1'
require 'fileutils'

RESULT = <<EOF
local function do_something()
  return 15;
end
return do_something()
EOF

class Wolverine
  class ScriptTemplatingTest < MiniTest::Unit::TestCase
    
    def setup
      base = Pathname.new('test/wolverine/lua')
      Wolverine.config.script_path = base
    end

    def teardown
      Wolverine.config.instrumentation = proc{}
    end

    def script
      @script ||= Wolverine::Script.new('test/wolverine/lua/outer.lua')
    end

    def test_templating
      assert_equal script.instance_variable_get('@content'), RESULT
    end

  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
wolverine-0.3.3 test/wolverine/script_templating_test.rb
wolverine-0.3.2 test/wolverine/script_templating_test.rb
wolverine-0.3.1 test/wolverine/script_templating_test.rb