decouplio 1.0.0alpha
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.circleci/config.yml +53 -0
- data/.dockerignore +12 -0
- data/.gitignore +13 -0
- data/.rspec +3 -0
- data/.rubocop.yml +106 -0
- data/.rubocop_todo.yml +147 -0
- data/.ruby-version +1 -0
- data/.vscode/settings.json +3 -0
- data/Dockerfile +12 -0
- data/Gemfile +8 -0
- data/LICENSE +21 -0
- data/LICENSE.txt +21 -0
- data/README.md +29 -0
- data/Rakefile +8 -0
- data/benchmarks/.ruby-version +1 -0
- data/benchmarks/Dockerfile +12 -0
- data/benchmarks/Gemfile +11 -0
- data/benchmarks/benchmarks.rb +527 -0
- data/bin/console +15 -0
- data/bin/setup +8 -0
- data/decouplio.gemspec +40 -0
- data/docker-compose.yml +18 -0
- data/docs/_config.yml +1 -0
- data/docs/benchmarks.md +1 -0
- data/docs/context.md +74 -0
- data/docs/context.rb +62 -0
- data/docs/doby.md +80 -0
- data/docs/doby.rb +38 -0
- data/docs/error_store.md +347 -0
- data/docs/error_store.rb +202 -0
- data/docs/fail.md +1016 -0
- data/docs/fail.rb +762 -0
- data/docs/index.md +25 -0
- data/docs/inner_action.md +63 -0
- data/docs/inner_action.rb +43 -0
- data/docs/logic_block.md +25 -0
- data/docs/octo.md +269 -0
- data/docs/octo.rb +164 -0
- data/docs/pass.md +309 -0
- data/docs/pass.rb +213 -0
- data/docs/quick_start.md +71 -0
- data/docs/quick_start.rb +38 -0
- data/docs/resq.md +263 -0
- data/docs/resq.rb +176 -0
- data/docs/step.md +737 -0
- data/docs/step.rb +526 -0
- data/docs/step_as_a_service.md +109 -0
- data/docs/step_as_a_service.rb +77 -0
- data/docs/wrap.md +232 -0
- data/docs/wrap.rb +137 -0
- data/lib/decouplio/action.rb +111 -0
- data/lib/decouplio/composer.rb +599 -0
- data/lib/decouplio/const/colors.rb +25 -0
- data/lib/decouplio/const/reserved_methods.rb +18 -0
- data/lib/decouplio/const/results.rb +13 -0
- data/lib/decouplio/const/types.rb +173 -0
- data/lib/decouplio/const/validations/action_option_class.rb +17 -0
- data/lib/decouplio/const/validations/common.rb +14 -0
- data/lib/decouplio/const/validations/fail.rb +34 -0
- data/lib/decouplio/const/validations/logic.rb +15 -0
- data/lib/decouplio/const/validations/octo.rb +44 -0
- data/lib/decouplio/const/validations/palp.rb +20 -0
- data/lib/decouplio/const/validations/pass.rb +32 -0
- data/lib/decouplio/const/validations/resq.rb +67 -0
- data/lib/decouplio/const/validations/step.rb +35 -0
- data/lib/decouplio/const/validations/wrap.rb +41 -0
- data/lib/decouplio/default_error_handler.rb +24 -0
- data/lib/decouplio/errors/action_class_error.rb +26 -0
- data/lib/decouplio/errors/base_error.rb +30 -0
- data/lib/decouplio/errors/error_store_error.rb +17 -0
- data/lib/decouplio/errors/extra_key_for_fail_error.rb +26 -0
- data/lib/decouplio/errors/extra_key_for_octo_error.rb +26 -0
- data/lib/decouplio/errors/extra_key_for_pass_error.rb +26 -0
- data/lib/decouplio/errors/extra_key_for_resq_error.rb +29 -0
- data/lib/decouplio/errors/extra_key_for_step_error.rb +23 -0
- data/lib/decouplio/errors/extra_key_for_wrap_error.rb +23 -0
- data/lib/decouplio/errors/fail_controversial_keys_error.rb +26 -0
- data/lib/decouplio/errors/fail_finish_him_error.rb +26 -0
- data/lib/decouplio/errors/fail_is_first_step_error.rb +18 -0
- data/lib/decouplio/errors/invalid_error_class_error.rb +29 -0
- data/lib/decouplio/errors/invalid_wrap_name_error.rb +23 -0
- data/lib/decouplio/errors/logic_is_not_defined_error.rb +23 -0
- data/lib/decouplio/errors/logic_redefinition_error.rb +23 -0
- data/lib/decouplio/errors/octo_block_is_not_defined_error.rb +18 -0
- data/lib/decouplio/errors/octo_controversial_keys_error.rb +26 -0
- data/lib/decouplio/errors/options_validation_error.rb +7 -0
- data/lib/decouplio/errors/palp_block_is_not_defined_error.rb +18 -0
- data/lib/decouplio/errors/palp_is_not_defined_error.rb +26 -0
- data/lib/decouplio/errors/palp_validation_error.rb +21 -0
- data/lib/decouplio/errors/pass_controversial_keys_error.rb +26 -0
- data/lib/decouplio/errors/pass_finish_him_error.rb +26 -0
- data/lib/decouplio/errors/required_options_is_missing_for_octo_error.rb +25 -0
- data/lib/decouplio/errors/resq_definition_error.rb +21 -0
- data/lib/decouplio/errors/resq_error_class_error.rb +29 -0
- data/lib/decouplio/errors/resq_handler_method_error.rb +26 -0
- data/lib/decouplio/errors/step_controversial_keys_error.rb +26 -0
- data/lib/decouplio/errors/step_finish_him_error.rb +26 -0
- data/lib/decouplio/errors/step_is_not_defined_for_fail_error.rb +26 -0
- data/lib/decouplio/errors/step_is_not_defined_for_step_error.rb +27 -0
- data/lib/decouplio/errors/step_is_not_defined_for_wrap_error.rb +26 -0
- data/lib/decouplio/errors/step_name_error.rb +20 -0
- data/lib/decouplio/errors/wrap_block_is_not_defined_error.rb +18 -0
- data/lib/decouplio/errors/wrap_controversial_keys_error.rb +26 -0
- data/lib/decouplio/errors/wrap_finish_him_error.rb +26 -0
- data/lib/decouplio/errors/wrap_klass_method_error.rb +23 -0
- data/lib/decouplio/flow.rb +17 -0
- data/lib/decouplio/logic_dsl.rb +96 -0
- data/lib/decouplio/octo_hash_case.rb +31 -0
- data/lib/decouplio/octo_options_validator.rb +89 -0
- data/lib/decouplio/options_validator.rb +566 -0
- data/lib/decouplio/processor.rb +20 -0
- data/lib/decouplio/steps/base_resq.rb +31 -0
- data/lib/decouplio/steps/base_step.rb +16 -0
- data/lib/decouplio/steps/doby.rb +32 -0
- data/lib/decouplio/steps/fail.rb +50 -0
- data/lib/decouplio/steps/if_condition_fail.rb +28 -0
- data/lib/decouplio/steps/if_condition_pass.rb +26 -0
- data/lib/decouplio/steps/inner_action_fail.rb +55 -0
- data/lib/decouplio/steps/inner_action_pass.rb +38 -0
- data/lib/decouplio/steps/inner_action_step.rb +51 -0
- data/lib/decouplio/steps/octo.rb +22 -0
- data/lib/decouplio/steps/pass.rb +35 -0
- data/lib/decouplio/steps/resq_fail.rb +10 -0
- data/lib/decouplio/steps/resq_pass.rb +10 -0
- data/lib/decouplio/steps/service_fail.rb +51 -0
- data/lib/decouplio/steps/service_pass.rb +36 -0
- data/lib/decouplio/steps/service_step.rb +47 -0
- data/lib/decouplio/steps/step.rb +43 -0
- data/lib/decouplio/steps/unless_condition_fail.rb +28 -0
- data/lib/decouplio/steps/unless_condition_pass.rb +26 -0
- data/lib/decouplio/steps/wrap.rb +62 -0
- data/lib/decouplio/validators/condition.rb +49 -0
- data/lib/decouplio/version.rb +5 -0
- data/lib/decouplio.rb +7 -0
- metadata +266 -0
@@ -0,0 +1,29 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/resq'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class ExtraKeyForResqError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Resq::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
format(
|
16
|
+
Decouplio::Const::Validations::Resq::NOT_ALLOWED_HANDLER_METHOD_VALUE,
|
17
|
+
@errored_option
|
18
|
+
),
|
19
|
+
format(
|
20
|
+
Decouplio::Const::Validations::Resq::DOES_NOT_ALLOW_OPTIONS,
|
21
|
+
@details
|
22
|
+
),
|
23
|
+
Decouplio::Const::Validations::Resq::ALLOWED_OPTIONS_MESSAGE,
|
24
|
+
Decouplio::Const::Validations::Resq::MANUAL_URL
|
25
|
+
]
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/step'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class ExtraKeyForStepError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Step::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
Decouplio::Const::Validations::Step::EXTRA_KEYS_ARE_NOT_ALLOWED,
|
17
|
+
Decouplio::Const::Validations::Step::ALLOWED_OPTIONS_MESSAGE,
|
18
|
+
Decouplio::Const::Validations::Step::MANUAL_URL
|
19
|
+
]
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/wrap'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class ExtraKeyForWrapError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Wrap::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
Decouplio::Const::Validations::Wrap::EXTRA_KEYS_ARE_NOT_ALLOWED,
|
17
|
+
Decouplio::Const::Validations::Wrap::ALLOWED_OPTIONS_MESSAGE,
|
18
|
+
Decouplio::Const::Validations::Wrap::MANUAL_URL
|
19
|
+
]
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/fail'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class FailControversialKeysError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Fail::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Fail::CONTROVERSIAL_KEYS,
|
18
|
+
*@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Fail::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Fail::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/fail'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class FailFinishHimError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Fail::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Common::WRONG_FINISH_HIM_VALUE,
|
18
|
+
@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Fail::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Fail::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/fail'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class FailCanNotBeTheFirstStepError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Fail::FIRST_STEP
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[]
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
@@ -0,0 +1,29 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/resq'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class InvalidErrorClassError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Resq::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
format(
|
16
|
+
Decouplio::Const::Validations::Resq::NOT_ALLOWED_EXCEPTION_CLASS,
|
17
|
+
@errored_option
|
18
|
+
),
|
19
|
+
format(
|
20
|
+
Decouplio::Const::Validations::Resq::ERROR_CLASS_INHERITANCE,
|
21
|
+
@details
|
22
|
+
),
|
23
|
+
Decouplio::Const::Validations::Resq::ALLOWED_OPTIONS_MESSAGE,
|
24
|
+
Decouplio::Const::Validations::Resq::MANUAL_URL
|
25
|
+
]
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/wrap'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class InvalidWrapNameError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Wrap::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
Decouplio::Const::Validations::Wrap::NAME_IS_EMPTY,
|
16
|
+
Decouplio::Const::Validations::Wrap::SPECIFY_NAME,
|
17
|
+
Decouplio::Const::Validations::Wrap::ALLOWED_OPTIONS_MESSAGE,
|
18
|
+
Decouplio::Const::Validations::Wrap::MANUAL_URL
|
19
|
+
]
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/logic'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class LogicIsNotDefinedError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Logic::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
format(
|
16
|
+
Decouplio::Const::Validations::Logic::NOT_DEFINED,
|
17
|
+
@errored_option
|
18
|
+
)
|
19
|
+
]
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/logic'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class LogicRedefinitionError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Logic::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
format(
|
16
|
+
Decouplio::Const::Validations::Logic::REDEFINITION,
|
17
|
+
@errored_option
|
18
|
+
)
|
19
|
+
]
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/octo'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class OctoBlockIsNotDefinedError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Octo::OCTO_BLOCK
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[]
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/octo'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class OctoControversialKeysError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Octo::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Octo::CONTROVERSIAL_KEYS,
|
18
|
+
*@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Octo::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Octo::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/palp'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class PalpBlockIsNotDefinedError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Palp::NOT_DEFINED
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[]
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/octo'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class PalpIsNotDefinedError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Octo::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option.join("\n"),
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Octo::PALPS_IS_NOT_DEFINED,
|
18
|
+
@details.join(', ')
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Octo::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Octo::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/palp'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class PalpValidationError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Palp::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
Decouplio::Const::Validations::Palp::DOES_NOT_ALLOW_ANY_OPTION,
|
16
|
+
Decouplio::Const::Validations::Palp::MANUAL_URL
|
17
|
+
]
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/pass'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class PassControversialKeysError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Pass::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Pass::CONTROVERSIAL_KEYS,
|
18
|
+
*@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Pass::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Pass::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/pass'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class PassFinishHimError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Pass::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Common::WRONG_FINISH_HIM_VALUE,
|
18
|
+
@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Pass::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Pass::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,25 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/octo'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class RequiredOptionsIsMissingForOctoError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Octo::REQUIRED_VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
format(
|
16
|
+
Decouplio::Const::Validations::Octo::OPTIONS_IS_REQUIRED,
|
17
|
+
@details
|
18
|
+
),
|
19
|
+
Decouplio::Const::Validations::Octo::ALLOWED_OPTIONS_MESSAGE,
|
20
|
+
Decouplio::Const::Validations::Octo::MANUAL_URL
|
21
|
+
]
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/resq'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class ResqDefinitionError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Resq::DEFINITION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
Decouplio::Const::Types::MAIN_FLOW_TYPES.join("\n"),
|
16
|
+
Decouplio::Const::Validations::Resq::MANUAL_URL
|
17
|
+
]
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
@@ -0,0 +1,29 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/resq'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class ResqErrorClassError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Resq::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
format(
|
16
|
+
Decouplio::Const::Validations::Resq::INVALID_ERROR_CLASS_VALUE,
|
17
|
+
@errored_option
|
18
|
+
),
|
19
|
+
format(
|
20
|
+
Decouplio::Const::Validations::Resq::WRONG_ERROR_CLASS,
|
21
|
+
@details
|
22
|
+
),
|
23
|
+
Decouplio::Const::Validations::Resq::ALLOWED_OPTIONS_MESSAGE,
|
24
|
+
Decouplio::Const::Validations::Resq::MANUAL_URL
|
25
|
+
]
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/resq'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class ResqHandlerMethodError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Resq::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
format(
|
16
|
+
Decouplio::Const::Validations::Resq::NOT_ALLOWED_HANDLER_METHOD_VALUE,
|
17
|
+
@errored_option
|
18
|
+
),
|
19
|
+
Decouplio::Const::Validations::Resq::HANDLER_METHOD_SHOULD_BE_A_SYMBOL,
|
20
|
+
Decouplio::Const::Validations::Resq::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Resq::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/step'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class StepControversialKeysError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Step::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Step::CONTROVERSIAL_KEYS,
|
18
|
+
*@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Step::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Step::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/step'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class StepFinishHimError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Step::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Common::WRONG_FINISH_HIM_VALUE,
|
18
|
+
@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Step::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Step::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/fail'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class StepIsNotDefinedForFailError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Fail::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Common::STEP_IS_NOT_DEFINED,
|
18
|
+
@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Fail::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Fail::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,27 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/step'
|
5
|
+
require_relative '../const/validations/common'
|
6
|
+
|
7
|
+
module Decouplio
|
8
|
+
module Errors
|
9
|
+
class StepIsNotDefinedForStepError < Decouplio::Errors::BaseError
|
10
|
+
def template
|
11
|
+
Decouplio::Const::Validations::Step::VALIDATION_ERROR_MESSAGE
|
12
|
+
end
|
13
|
+
|
14
|
+
def interpolation_values
|
15
|
+
[
|
16
|
+
@errored_option,
|
17
|
+
format(
|
18
|
+
Decouplio::Const::Validations::Common::STEP_IS_NOT_DEFINED,
|
19
|
+
@details
|
20
|
+
),
|
21
|
+
Decouplio::Const::Validations::Step::ALLOWED_OPTIONS_MESSAGE,
|
22
|
+
Decouplio::Const::Validations::Step::MANUAL_URL
|
23
|
+
]
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative 'base_error'
|
4
|
+
require_relative '../const/validations/wrap'
|
5
|
+
|
6
|
+
module Decouplio
|
7
|
+
module Errors
|
8
|
+
class StepIsNotDefinedForWrapError < Decouplio::Errors::BaseError
|
9
|
+
def template
|
10
|
+
Decouplio::Const::Validations::Wrap::VALIDATION_ERROR_MESSAGE
|
11
|
+
end
|
12
|
+
|
13
|
+
def interpolation_values
|
14
|
+
[
|
15
|
+
@errored_option,
|
16
|
+
format(
|
17
|
+
Decouplio::Const::Validations::Common::STEP_IS_NOT_DEFINED,
|
18
|
+
@details
|
19
|
+
),
|
20
|
+
Decouplio::Const::Validations::Wrap::ALLOWED_OPTIONS_MESSAGE,
|
21
|
+
Decouplio::Const::Validations::Wrap::MANUAL_URL
|
22
|
+
]
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|