Skip to content

rimian/rspec-helpers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RSpec Helpers

This is a spike for context helpers.

require 'spec_helper'

RSpec.configure do |config|
  def my_context_helper(arg)
    @my_var = arg
  end

  def my_operation_helper(&block)
    operation = block.call if block_given?

    # do some operation with the context
  end
end

RSpec.describe 'Smoke Test' do
  my_context_helper 3

  my_operation_helper do
    'hello world'
  end
end

CODE OF CONDUCT

See CODE OF CONDUCT

About

testing out RSpec context helpers and stuff

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages