Sha256: 739b920038c7dc0eaac8c92572e6f9babeaf1dd3609d21ea340fcf0722b3ed4f
Contents?: true
Size: 1.44 KB
Versions: 2
Compression:
Stored size: 1.44 KB
Contents
# frozen_string_literal: true require_relative "printers/base" require_relative "printers/error" require_relative "printers/failure" require_relative "printers/null" require_relative "printers/success" module ConvenientService module RSpec module Matchers module Custom module Results class Base module Entities module Printers class << self ## # @api private # # @param matcher [ConvenientService::RSpec::Matchers::Custom::Results::Base] # @return [ConvenientService::RSpec::Matchers::Custom::Results::Base::Entities::Printers::Base] # def create(matcher:) return Entities::Printers::Null.new(matcher: matcher) unless matcher.result case matcher.result.status.to_sym when :success Entities::Printers::Success.new(matcher: matcher) when :failure Entities::Printers::Failure.new(matcher: matcher) when :error Entities::Printers::Error.new(matcher: matcher) else Entities::Printers::Null.new(matcher: matcher) end end end end end end end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems