Sha256: 239ceb3d739c874b9f7251c90677ae2a7a4545b338f63788af53c1bdbe631e3a

Contents?: true

Size: 438 Bytes

Versions: 15

Compression:

Stored size: 438 Bytes

Contents

# frozen_string_literal: true

class Grumlin::Middlewares::FindBlocklistedSteps < Grumlin::Middlewares::Middleware
  def initialize(app, *steps)
    super(app)
    @validator = Grumlin::QueryValidators::BlocklistedStepsValidator.new(*steps)
  end

  def call(env)
    @validator.validate!(env[:steps_without_shortcuts])
    @app.call(env)
    env[:parsed_results] = @app.call(env).flat_map { |item| Grumlin::Typing.cast(item) }
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
grumlin-1.2.0 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.1.0 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.4 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.3 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.3.beta1 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.2 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.1 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.0 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.0.rc7 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.0.rc6 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.0.rc5 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.0.rc4 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.0.rc3 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.0.rc2 lib/grumlin/middlewares/find_blocklisted_steps.rb
grumlin-1.0.0.rc1 lib/grumlin/middlewares/find_blocklisted_steps.rb