Skip to content

Instantly share code, notes, and snippets.

View rubendinho's full-sized avatar

Ruben Izmailyan rubendinho

View GitHub Profile
@rubendinho
rubendinho / factories_spec.rb
Created September 15, 2022 17:30
Testing your FactoryBot factories and defined traits
require 'rails_helper'
RSpec.describe 'Factories', :vcr do
FactoryBot.factories.each do |factory|
describe "The :#{factory.name} factory" do
describe 'base factory' do
it 'is valid' do
expect(build(factory.name.to_sym)).to be_valid
end
end
@rubendinho
rubendinho / plaid_integration_test_with_capybara.rb
Created August 13, 2019 21:21 — forked from iloveitaly/plaid_integration_test_with_capybara.rb
Test Plaid instant bank account verification with rspec + capybara
within_frame 'plaid-link-iframe-1' do
find('[data-institution="pnc"]').click
fill_in 'username', with: 'plaid_test'
fill_in 'password', with: 'plaid_good'
click_on 'Submit'
page.has_content?('Security Question', wait: 15)
fill_in 'Answer', with: 'tomato', wait: 15
@rubendinho
rubendinho / bump-version.sh
Created August 16, 2017 16:59 — forked from mareksuscak/bump-version.sh
Bump version shell script.
#!/bin/bash
# Thanks goes to @pete-otaqui for the initial gist:
# https://gist.github.com/pete-otaqui/4188238
#
# Original version modified by Marek Suscak
#
# works with a file called VERSION in the current directory,
# the contents of which should be a semantic version number
# such as "1.2.3" or even "1.2.3-beta+001.ab"