Skip to content
This repository was archived by the owner on Jun 9, 2019. It is now read-only.
This repository was archived by the owner on Jun 9, 2019. It is now read-only.

Methods to detect step sequence #23

@paulschreiber

Description

@paulschreiber

It would be nice to have methods to detect step sequence. Something like step_is_after?(:step) and step_is_before?(:step).

This way, I could try up all the step checking blocks

before do |voter|
  redirect_to_step :address unless voter.state
end

i.e.

before :each do
  if step_is_before?(:check_registration)
    redirect_to_step :start unless voter.email
  else
    redirect_to_step :address unless voter.state
  end
end

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions