[DRE-commits] [test-kitchen] 07/13: Look for templates in /usr/share/test-kitchen/templates/

Hleb Valoshka tsfgnu-guest at moszumanska.debian.org
Fri Aug 5 12:46:55 UTC 2016


This is an automated email from the git hooks/post-receive script.

tsfgnu-guest pushed a commit to branch patch-queue/master
in repository test-kitchen.

commit f1678340c0d33de6a5740593a0e8391b084ec77c
Author: Hleb Valoshka <375gnu at gmail.com>
Date:   Wed Jul 8 11:38:02 2015 +0300

    Look for templates in /usr/share/test-kitchen/templates/
---
 lib/kitchen/generator/driver_create.rb | 4 +++-
 lib/kitchen/generator/init.rb          | 4 +++-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/lib/kitchen/generator/driver_create.rb b/lib/kitchen/generator/driver_create.rb
index 5af32c3..4196d81 100644
--- a/lib/kitchen/generator/driver_create.rb
+++ b/lib/kitchen/generator/driver_create.rb
@@ -39,7 +39,9 @@ module Kitchen
 
       # Invoke the command.
       def create
-        self.class.source_root(Kitchen.source_root.join("templates", "driver"))
+        self.class.source_root(File.join(
+          File.dirname(__FILE__),
+          "../../../../../share/test-kitchen/templates/driver"))
 
         create_core_files
         create_source_files
diff --git a/lib/kitchen/generator/init.rb b/lib/kitchen/generator/init.rb
index c14d7a7..475337a 100644
--- a/lib/kitchen/generator/init.rb
+++ b/lib/kitchen/generator/init.rb
@@ -58,7 +58,9 @@ module Kitchen
 
       # Invoke the command.
       def init
-        self.class.source_root(Kitchen.source_root.join("templates", "init"))
+        self.class.source_root(File.join(
+          File.dirname(__FILE__),
+          "../../../../../share/test-kitchen/templates/init"))
 
         create_kitchen_yaml
         create_chefignore

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/test-kitchen.git



More information about the Pkg-ruby-extras-commits mailing list