Skip to content

Commit

Permalink
Merge pull request didww#25 from senid231/freshing-up-demo
Browse files Browse the repository at this point in the history
freshing up demo

use ruby 2.7.2, add bundle audit, update bundler to 2.X.X version, remove faker from rails application
  • Loading branch information
senid231 committed Feb 1, 2021
2 parents 380b1a3 + 818fa6f commit d6f7426
Show file tree
Hide file tree
Showing 8 changed files with 55 additions and 38 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/tests.yml
@@ -0,0 +1,20 @@
name: Tests
on:
pull_request:
push:
branches:
- master

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
with:
ruby-version: 2.7
- name: Run tests
run: |
gem install bundler -v 2.2.7
bundle install
bundle exec rake
1 change: 0 additions & 1 deletion .ruby-gemset

This file was deleted.

2 changes: 1 addition & 1 deletion .ruby-version
@@ -1 +1 @@
2.4.2
2.7.2
11 changes: 6 additions & 5 deletions Gemfile
Expand Up @@ -3,7 +3,7 @@ git_source(:github) do |repo_name|
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?('/')
"https://github.com/#{repo_name}.git"
end
ruby '2.4.2'
ruby '2.7.2'
gem 'rails', '~> 5.1.4'
gem 'puma', '~> 3.12'
gem 'sass-rails', '~> 5.0'
Expand All @@ -30,6 +30,7 @@ group :development do
gem 'listen', '>= 3.0.5', '< 3.2'
gem 'spring'
gem 'spring-watcher-listen', '~> 2.0.0'
gem 'bundle-audit', require: false
end
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]

Expand All @@ -56,10 +57,10 @@ group :development do
gem 'awesome_print'
end
group :development, :test do
gem 'factory_bot_rails'
gem 'faker'
gem 'rspec-rails'
gem 'rubocop'
gem 'factory_bot_rails', require: false
gem 'faker', require: false
gem 'rspec-rails', require: false
gem 'rubocop', require: false
end
group :test do
gem 'launchy'
Expand Down
22 changes: 14 additions & 8 deletions Gemfile.lock
Expand Up @@ -54,6 +54,11 @@ GEM
bootstrap-datepicker-rails (1.7.1.1)
railties (>= 3.0)
builder (3.2.3)
bundle-audit (0.1.0)
bundler-audit
bundler-audit (0.7.0.1)
bundler (>= 1.2.0, < 3)
thor (>= 0.18, < 2)
byebug (9.1.0)
capybara (2.16.1)
addressable
Expand Down Expand Up @@ -101,7 +106,7 @@ GEM
font-awesome-rails (4.7.0.2)
railties (>= 3.2, < 5.2)
formatador (0.2.5)
globalid (0.4.1)
globalid (0.4.2)
activesupport (>= 4.2.0)
guard (2.14.1)
formatador (>= 0.2.4)
Expand All @@ -112,8 +117,8 @@ GEM
pry (>= 0.9.12)
shellany (~> 0.0)
thor (>= 0.18.1)
guard-bundler (2.1.0)
bundler (~> 1.0)
guard-bundler (2.2.1)
bundler (>= 1.3.0, < 3)
guard (~> 2.2)
guard-compat (~> 1.1)
guard-compat (1.2.1)
Expand Down Expand Up @@ -162,7 +167,7 @@ GEM
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
lumberjack (1.0.12)
mail (2.7.0)
mail (2.7.1)
mini_mime (>= 0.1.1)
method_source (0.9.0)
mini_mime (1.0.0)
Expand All @@ -171,7 +176,7 @@ GEM
multi_json (1.12.2)
multipart-post (2.0.0)
nenv (0.3.0)
nio4r (2.1.0)
nio4r (2.5.4)
nokogiri (1.8.1)
mini_portile2 (~> 2.3.0)
notiffany (0.1.1)
Expand Down Expand Up @@ -311,7 +316,7 @@ GEM
railties (>= 5.0)
websocket-driver (0.6.5)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.3)
websocket-extensions (0.1.5)
will_paginate (3.1.6)
will_paginate-bootstrap (1.0.1)
will_paginate (>= 3.0.3)
Expand All @@ -324,6 +329,7 @@ PLATFORMS
DEPENDENCIES
awesome_print
bootstrap-datepicker-rails
bundle-audit
byebug
capybara (~> 2.13)
coffee-rails (~> 4.2)
Expand Down Expand Up @@ -368,7 +374,7 @@ DEPENDENCIES
will_paginate-bootstrap

RUBY VERSION
ruby 2.4.2p198
ruby 2.7.2p137

BUNDLED WITH
1.16.1
2.2.7
12 changes: 12 additions & 0 deletions Rakefile
Expand Up @@ -4,3 +4,15 @@
require_relative 'config/application'

Rails.application.load_tasks

if Rails.env.development? || Rails.env.test?
require 'rubocop/rake_task'
# require 'rspec/core/rake_task'
require 'bundler/audit/task'

# RSpec::Core::RakeTask.new(:spec)
Bundler::Audit::Task.new
RuboCop::RakeTask.new

task default: ['bundle:audit', :rubocop]
end
4 changes: 2 additions & 2 deletions spec/rails_helper.rb
Expand Up @@ -24,11 +24,11 @@

# Checks for pending migrations and applies them before tests are run.
# If you are not using ActiveRecord, you can remove this line.
ActiveRecord::Migration.maintain_test_schema!
# ActiveRecord::Migration.maintain_test_schema!

RSpec.configure do |config|
# Remove this line if you're not using ActiveRecord or ActiveRecord fixtures
config.fixture_path = "#{::Rails.root}/spec/fixtures"
# config.fixture_path = "#{::Rails.root}/spec/fixtures"

# If you're not using ActiveRecord, or you'd prefer not to run each of your
# examples within a transaction, remove the following line or assign false
Expand Down
21 changes: 0 additions & 21 deletions spec/support/database_cleaner.rb

This file was deleted.

0 comments on commit d6f7426

Please sign in to comment.