Skip to content

Instantly share code, notes, and snippets.

View nativestranger's full-sized avatar
🎯
Focusing

Eric Arnold nativestranger

🎯
Focusing
View GitHub Profile

senior developer (Rails & React) @ fast growing cannabis testing lab

(Remote or paid relocation)

Overview

We’re looking for a seasoned developer to join our new engineering team. You’ll be the second full-time engineer at the company, and will have a massive impact on our success and engineering culture. You must be fluent across the full stack and highly experienced in developing Rails applications.

Our stack

  • Ruby on Rails
  • React
class Config4
def self.config4(name)
config = Rails.application.config_for(name)
Class.new do
config.each_pair do |key, value|
define_singleton_method(key) { value }
define_singleton_method("#{key}=") do |new_value|
define_singleton_method(key) { new_value }
end
@browser = Watir::Browser.new(
:remote,
url: "http://#{ ENV['SAUCE_USER_NAME'] }:#{ ENV['SAUCE_API_KEY'] }@ondemand.saucelabs.com:80/wd/hub",
desired_capabilities: { 'browserName' => ENV['SELENIUM_BROWSER'],
'version' => ENV['SELENIUM_VERSION'],
'platform' => ENV['SELENIUM_PLATFORM'] }
)
Capybara.register_driver :sauce do |app|
Capybara::Selenium::Driver.new(
app,
browser: :remote,
url: "http://#{ ENV['SAUCE_USER_NAME'] }:#{ ENV['SAUCE_API_KEY'] }@ondemand.saucelabs.com:80/wd/hub",
desired_capabilities: { 'browserName' => ENV['SELENIUM_BROWSER'],
'version' => ENV['SELENIUM_VERSION'],
'platform' => ENV['SELENIUM_PLATFORM'] }
)
end
# within app/admin/users.rb
member_action :impersonate, :method => :get do
user = User.find(params[:id])
begin
flash[:notice] = "Successfully logged in as : #{user.email} #{view_context.link_to('Be careful!', root_path)}".html_safe
warden.set_user(resource,{:scope=>:user,:run_callbacks=>false})
rescue
flash[:error] = "Unable to log you in. Poop."
end
source 'https://rubygems.org'
gem 'rspec', group: :test
ruby "2.3.0"