From c585e76414e14a907a13e3ad4482fb42025b5f43 Mon Sep 17 00:00:00 2001 From: Nick Sutterer Date: Sat, 18 Nov 2023 12:31:26 +0100 Subject: [PATCH] add docs test. --- test/docs/wiring_api_test.rb | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/test/docs/wiring_api_test.rb b/test/docs/wiring_api_test.rb index 13727c7..2ce2586 100644 --- a/test/docs/wiring_api_test.rb +++ b/test/docs/wiring_api_test.rb @@ -62,25 +62,28 @@ class Create < Trailblazer::Activity::Railway end end -#@ Output => End +#@ failure/Output => End class OutputOnLeft_WiringApiDocsTest < Minitest::Spec Memo = Class.new + #:left module Memo::Activity class Create < Trailblazer::Activity::Railway step :validate step :save - left :fix_errors, + left :handle_errors, Output(:success) => Track(:success) step :notify #~meths - include T.def_steps(:validate, :save, :fix_errors, :notify) + include T.def_steps(:validate, :save, :handle_errors, :notify) + #~meths end end end + #:left end it "what" do assert_invoke Memo::Activity::Create, seq: "[:validate, :save, :notify]" - assert_invoke Memo::Activity::Create, seq: "[:validate, :save, :fix_errors, :notify]", save: false - assert_invoke Memo::Activity::Create, seq: "[:validate, :save, :fix_errors]", save: false, fix_errors: false, terminus: :failure + assert_invoke Memo::Activity::Create, seq: "[:validate, :save, :handle_errors, :notify]", save: false + assert_invoke Memo::Activity::Create, seq: "[:validate, :save, :handle_errors]", save: false, handle_errors: false, terminus: :failure end end