File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -158,8 +158,8 @@ def run_hook(hook, **extra_details)
158158 say "Running the #{ hook } hook..." , :magenta
159159 run_locally do
160160 execute *KAMAL . hook . run ( hook , **details , **extra_details )
161- rescue SSHKit ::Command ::Failed
162- raise HookError . new ( "Hook `#{ hook } ` failed" )
161+ rescue SSHKit ::Command ::Failed => e
162+ raise HookError . new ( "Hook `#{ hook } ` failed: \n #{ e . message } " )
163163 end
164164 end
165165 end
Original file line number Diff line number Diff line change @@ -51,7 +51,8 @@ class CliBuildTest < CliTestCase
5151 test "push pre-build hook failure" do
5252 fail_hook ( "pre-build" )
5353
54- assert_raises ( Kamal ::Cli ::HookError ) { run_command ( "push" ) }
54+ error = assert_raises ( Kamal ::Cli ::HookError ) { run_command ( "push" ) }
55+ assert_equal "Hook `pre-build` failed:\n failed" , error . message
5556
5657 assert @executions . none? { |args | args [ 0 ..2 ] == [ :docker , :buildx , :build ] }
5758 end
You can’t perform that action at this time.
0 commit comments