# spec/support/user_support.rb
RSpec.configure do |config|
config.include UserHelper, type: :user
config.include_context "user_context", type: :use
end
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Example: | |
# | |
# > TablesFinder.call(column_name: 'site_id') | |
# => ['events', 'users'] | |
class TablesFinder | |
VALID_ATTRIBUTES = %w[ | |
COLUMN_NAME | |
].freeze | |
def self.call(args) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Example usage ============= | |
# | |
# describe :namespace do | |
# include RakeTasksHelper | |
# | |
# describe ':task' do | |
# it 'works' do | |
# invoke_task('namespace:task') | |
# end | |
# end |
To automatically open pages saved when using save_and_open_page
we need to add the launchy gem to the test environment.
# Gemfile
group :test do
gem 'launchy', '~> 2.4', '>= 2.4.3'
end