Sha256: b381b6c2c66d817a389f87c4c86b54e2f2bda2a1a12759b1ff0b29f1f23cb98a

Contents?: true

Size: 1.5 KB

Versions: 4

Compression:

Stored size: 1.5 KB

Contents

# frozen_string_literal: true

##
# Usage example:
#
# result = ConvenientService::Examples::Dry::V1::Gemfile.format(path: "Gemfile")
# result = ConvenientService::Examples::Dry::V1::Gemfile.format(path: "spec/cli/gemfile/format/fixtures/Gemfile")
#
module ConvenientService
  module Examples
    module Dry
      module V1
        class Gemfile
          class DryService
            module Config
              include Support::Concern

              included do
                include ConvenientService::Standard::V1::Config

                ##
                # NOTE: `AssignsAttributesInConstructor::UsingDryInitializer` plugin.
                #
                concerns do
                  use ConvenientService::Plugins::Common::AssignsAttributesInConstructor::UsingDryInitializer::Concern
                end

                ##
                # NOTE: `HasJSendResultParamsValidations::UsingDryValidation` plugin.
                #
                concerns do
                  use ConvenientService::Plugins::Service::HasJSendResultParamsValidations::UsingDryValidation::Concern
                end

                middlewares :result do
                  insert_before \
                    ConvenientService::Plugins::Service::RaisesOnNotResultReturnValue::Middleware,
                    ConvenientService::Plugins::Service::HasJSendResultParamsValidations::UsingDryValidation::Middleware.with(status: :failure)
                end
              end
            end
          end
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
convenient_service-0.17.0 lib/convenient_service/examples/dry/v1/gemfile/dry_service/config.rb
convenient_service-0.16.0 lib/convenient_service/examples/dry/v1/gemfile/dry_service/config.rb
convenient_service-0.15.0 lib/convenient_service/examples/dry/v1/gemfile/dry_service/config.rb
convenient_service-0.14.0 lib/convenient_service/examples/dry/v1/gemfile/dry_service/config.rb