require "spec_helper" describe Cbt::Creator do describe "#find_tpl" do subject(:crt) { Cbt::Creator.new(config_file: "examples/config/components.yml") } it "find tpl for simple module" do crt.find_tpl(Cbt::LuaModule.new('utils', 'util')).should eq(File.expand_path("templates/part.lua.erb")) end it "find tpl for simple Class" do crt.find_tpl(Cbt::LuaModule.new('utils', 'Util')).should eq(File.expand_path("templates/Class.lua.erb")) end it "find tpl for simple module with super class" do crt.find_tpl(Cbt::LuaModule.new('utils', 'util