Sha256: 3727589f962395e3fae94848baaa84914381156c68def312ec98b71b4f1f421f

Contents?: true

Size: 1.57 KB

Versions: 5

Compression:

Stored size: 1.57 KB

Contents

require 'test_helper'

class StepPositionsTest < ActiveSupport::IntegrationCase

  test 'on first' do
    step = :first
    visit(step_position_path(step))
    assert has_content?('first step is the current step')   # current_step?
    assert true                                             # past_step?
    assert has_content?('last_step step is a future step')  # future_step?
    assert has_content?('second step is a future step')     # future_step?
    assert true                                             # previous_step?
    assert has_content?('second step is the next step')     # next_step?
  end

  test 'on second' do
    step = :second
    visit(step_position_path(step))
    assert has_content?('second step is the current step')  # current_step?
    assert has_content?('first step is a past step')        # past_step?
    assert has_content?('last_step step is a future step')  # future_step?
    assert has_content?('first step was the previous step') # previous_step?
    assert has_content?('last_step step is the next step')  # next_step?
  end

  test 'string-based steps' do
    visit(string_step_path('second'))
    assert has_content?('second step is the current step')  # current_step?
    assert has_content?('first step is a past step')        # past_step?
    assert has_content?('last_step step is a future step')  # future_step?
    assert has_content?('first step was the previous step') # previous_step?
    assert has_content?('last_step step is the next step')  # next_step?
  end
end

  # current_step?
  # past_step?
  # future_step?
  # previous_step?
  # next_step?

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
wicked-1.0.2 test/integration/steps_test.rb
wicked-1.0.1 test/integration/steps_test.rb
wicked-1.0.0 test/integration/steps_test.rb
wicked-0.6.1 test/integration/steps_test.rb
wicked-0.6.0 test/integration/steps_test.rb