Skip to content
Browse files

Update crates for pallet 0.6.3

  • Loading branch information...
1 parent 4f4b6f1 commit 236b4c9d0297e9afdbe161142f571694d9a2b129 @hugoduncan hugoduncan committed
View
2 cruise-control-rb/test/pallet/crate/cruise_control_rb_test.clj
@@ -9,7 +9,7 @@
clojure.test
pallet.test-utils))
-(use-fixtures :once with-ubuntu-script-template)
+(use-fixtures :once with-ubuntu-script-template with-bash-script-language)
(deftest cruise-control-rb-job-test
(is (= (stevedore/checked-script
View
12 hudson/test/pallet/crate/hudson_test.clj
@@ -25,10 +25,14 @@
(def parameters {:host
{:id
- {:tomcat {:owner "tomcat6"
- :group "tomcat6"
- :config-path "/etc/tomcat6/"
- :base "/var/lib/tomcat6/"}}}})
+ {:tomcat
+ {:default
+ {:owner "tomcat6"
+ :group "tomcat6"
+ :config-path "/etc/tomcat6/"
+ :base "/var/lib/tomcat6/"
+ :deploy "/var/lib/tomcat6/webapps"}}}}})
+
(deftest hudson-tomcat-test
(is (= (first
(build-actions/build-actions
View
2 iptables/test/pallet/crate/iptables_test.clj
@@ -10,7 +10,7 @@
(:use clojure.test
pallet.test-utils))
-(use-fixtures :once with-ubuntu-script-template)
+(use-fixtures :once with-ubuntu-script-template with-bash-script-language)
(def remote-file* (action/action-fn remote-file/remote-file-action))
View
5 nagios/test/pallet/crate/nagios_test.clj
@@ -12,7 +12,10 @@
[clojure.string :as string])
(:use clojure.test))
-(use-fixtures :once test-utils/with-ubuntu-script-template)
+(use-fixtures
+ :once
+ test-utils/with-ubuntu-script-template
+ test-utils/with-bash-script-language)
(def remote-file* (action/action-fn remote-file/remote-file-action))
View
2 resolv/test/pallet/crate/resolv_test.clj
@@ -5,7 +5,7 @@
(:require
[pallet.build-actions :as build-actions]))
-(use-fixtures :once with-ubuntu-script-template)
+(use-fixtures :once with-ubuntu-script-template with-bash-script-language)
(with-private-vars [pallet.crate.resolv
[write-key-value write-option write-options write
View
5 rubygems/test/pallet/crate/rubygems_test.clj
@@ -7,10 +7,9 @@
[pallet.stevedore :as stevedore])
(:use
clojure.test
- pallet.test-utils
-))
+ pallet.test-utils))
-(use-fixtures :once with-ubuntu-script-template)
+(use-fixtures :once with-ubuntu-script-template with-bash-script-language)
(deftest gem-script-test
(is (= "gem install fred"
View
6 ssh-key/test/pallet/crate/ssh_key_test.clj
@@ -38,7 +38,11 @@
(var auth_file
"$(getent passwd fred | cut -d: -f6)/.ssh/authorized_keys")
(if-not (fgrep (quoted "key1") @auth_file)
- (echo (quoted "key1") ">>" @auth_file)))))
+ (echo (quoted "key1") ">>" @auth_file)))
+ (exec-script/exec-checked-script
+ "Set selinux permissions"
+ (~lib/selinux-file-type
+ "$(getent passwd fred | cut -d: -f6)/.ssh" "user_home_t"))))
(first
(build-actions/build-actions
{}
View
23 tomcat/test/pallet/crate/tomcat_test.clj
@@ -28,7 +28,7 @@
clojure.test
pallet.test-utils))
-(use-fixtures :once with-ubuntu-script-template)
+(use-fixtures :once with-ubuntu-script-template with-bash-script-language)
(deftest install-test
(is (= (first
@@ -37,7 +37,7 @@
(package/package-manager :update)
(package/package "tomcat6")
(directory/directory
- (stevedore/script (user-home "tomcat6"))
+ (stevedore/script (~lib/user-home "tomcat6"))
:owner "tomcat6" :group "tomcat6" :mode "0755")
(exec-script/exec-checked-script
"Check tomcat is at /var/lib/tomcat6/"
@@ -70,14 +70,17 @@
(build-actions/build-actions
{:parameters
{:host {:id {:tomcat
- {:default {:base "/p/" :owner "o" :group "g"}}}}}}
+ {:default {:base "/p/" :deploy "/p/webapps"
+ :owner "o" :group "g"}}}}}}
(tomcat/deploy nil :remote-file "file.war"))))))
(deftest tomcat-undeploy-all-test
(is (= "rm -r -f /p/webapps/*\n"
(first
(build-actions/build-actions
- {:parameters {:host {:id {:tomcat {:default {:base "/p/"}}}}}}
+ {:parameters
+ {:host {:id {:tomcat {:default
+ {:base "/p/" :deploy "/p/webapps"}}}}}}
(tomcat/undeploy-all))))))
(deftest tomcat-undeploy-test
@@ -88,7 +91,9 @@
(file/file "/p/webapps/ROOT.war" :action :delete)))
(first
(build-actions/build-actions
- {:parameters {:host {:id {:tomcat {:default {:base "/p/"}}}}}}
+ {:parameters
+ {:host {:id {:tomcat {:default {:base "/p/"
+ :deploy "/p/webapps"}}}}}}
(tomcat/undeploy nil)))))
(is (= (first
(build-actions/build-actions
@@ -97,7 +102,9 @@
(file/file "/p/webapps/app.war" :action :delete)))
(first
(build-actions/build-actions
- {:parameters {:host {:id {:tomcat {:default {:base "/p/"}}}}}}
+ {:parameters
+ {:host {:id {:tomcat {:default {:base "/p/"
+ :deploy "/p/webapps"}}}}}}
(tomcat/undeploy :app)))))
(is (= (first
(build-actions/build-actions
@@ -106,7 +113,9 @@
(file/file "/p/webapps/foo.war" :action :delete)))
(first
(build-actions/build-actions
- {:parameters {:host {:id {:tomcat {:default {:base "/p/"}}}}}}
+ {:parameters
+ {:host {:id {:tomcat {:default {:base "/p/"
+ :deploy "/p/webapps"}}}}}}
(tomcat/undeploy "foo"))))))
(deftest tomcat-policy-test

0 comments on commit 236b4c9

Please sign in to comment.
Something went wrong with that request. Please try again.