Browse Source

lint: add frozen string literal magic comment

develop
Bèr Kessels 1 year ago
parent
commit
84aba45874
62 changed files with 118 additions and 0 deletions
  1. 2
    0
      Gemfile
  2. 2
    0
      Rakefile
  3. 2
    0
      app/channels/application_cable/channel.rb
  4. 2
    0
      app/channels/application_cable/connection.rb
  5. 2
    0
      app/controllers/application_controller.rb
  6. 2
    0
      app/controllers/professionals_controller.rb
  7. 2
    0
      app/helpers/application_helper.rb
  8. 2
    0
      app/helpers/public_helper.rb
  9. 2
    0
      app/jobs/application_job.rb
  10. 2
    0
      app/mailers/application_mailer.rb
  11. 2
    0
      app/models/application_record.rb
  12. 2
    0
      app/models/profile.rb
  13. 2
    0
      app/models/profile/contact_detail.rb
  14. 2
    0
      app/view_models/profile/contact_detail_view_model.rb
  15. 2
    0
      bin/rails
  16. 2
    0
      bin/rake
  17. 2
    0
      bin/setup
  18. 1
    0
      bin/spring
  19. 1
    0
      bin/webpack
  20. 1
    0
      bin/webpack-dev-server
  21. 2
    0
      bin/yarn
  22. 2
    0
      config.ru
  23. 2
    0
      config/application.rb
  24. 2
    0
      config/boot.rb
  25. 2
    0
      config/environment.rb
  26. 2
    0
      config/environments/development.rb
  27. 2
    0
      config/environments/production.rb
  28. 2
    0
      config/environments/test.rb
  29. 1
    0
      config/initializers/application_controller_renderer.rb
  30. 2
    0
      config/initializers/assets.rb
  31. 1
    0
      config/initializers/backtrace_silencers.rb
  32. 1
    0
      config/initializers/content_security_policy.rb
  33. 2
    0
      config/initializers/cookies_serializer.rb
  34. 2
    0
      config/initializers/filter_parameter_logging.rb
  35. 2
    0
      config/initializers/friendly_id.rb
  36. 1
    0
      config/initializers/inflections.rb
  37. 2
    0
      config/initializers/mahout_instance.rb
  38. 1
    0
      config/initializers/mime_types.rb
  39. 2
    0
      config/initializers/wrap_parameters.rb
  40. 2
    0
      config/puma.rb
  41. 2
    0
      config/routes.rb
  42. 2
    0
      config/spring.rb
  43. 2
    0
      db/migrate/20200410153131_enable_pgcrypto_extension.rb
  44. 2
    0
      db/migrate/20200410160000_create_profiles.rb
  45. 2
    0
      db/migrate/20200412131932_create_active_storage_tables.active_storage.rb
  46. 2
    0
      db/migrate/20200413130444_add_last_activity_at_to_profiles.rb
  47. 2
    0
      db/migrate/20200416094746_add_contact_details_to_profiles.rb
  48. 2
    0
      db/migrate/20200430111245_add_slug_to_profiles.rb
  49. 2
    0
      db/migrate/20200430111256_create_friendly_id_slugs.rb
  50. 2
    0
      db/schema.rb
  51. 2
    0
      test/application_system_test_case.rb
  52. 2
    0
      test/channels/application_cable/connection_test.rb
  53. 2
    0
      test/controllers/professionals_controller_test.rb
  54. 2
    0
      test/helpers/public_helper_test.rb
  55. 2
    0
      test/models/profile/contact_detail_test.rb
  56. 2
    0
      test/models/profile_test.rb
  57. 4
    0
      test/support/workflows.rb
  58. 2
    0
      test/support/workflows/profile_creator.rb
  59. 2
    0
      test/support/workflows/profile_importer.rb
  60. 2
    0
      test/system/list_professionals_test.rb
  61. 2
    0
      test/system/view_professional_test.rb
  62. 2
    0
      test/view_models/profile/contact_detail_view_model_test.rb

+ 2
- 0
Gemfile View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }


+ 2
- 0
Rakefile View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.


+ 2
- 0
app/channels/application_cable/channel.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

module ApplicationCable
class Channel < ActionCable::Channel::Base
end

+ 2
- 0
app/channels/application_cable/connection.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

module ApplicationCable
class Connection < ActionCable::Connection::Base
end

+ 2
- 0
app/controllers/application_controller.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class ApplicationController < ActionController::Base
include Pagy::Backend


+ 2
- 0
app/controllers/professionals_controller.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class ProfessionalsController < ApplicationController
layout 'public'


+ 2
- 0
app/helpers/application_helper.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

module ApplicationHelper
include Pagy::Frontend
end

+ 2
- 0
app/helpers/public_helper.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

##
# Helpers for public views and templates
module PublicHelper

+ 2
- 0
app/jobs/application_job.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class ApplicationJob < ActiveJob::Base
# Automatically retry jobs that encountered a deadlock
# retry_on ActiveRecord::Deadlocked

+ 2
- 0
app/mailers/application_mailer.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class ApplicationMailer < ActionMailer::Base
default from: 'from@example.com'
layout 'mailer'

+ 2
- 0
app/models/application_record.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class ApplicationRecord < ActiveRecord::Base
self.abstract_class = true
end

+ 2
- 0
app/models/profile.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class Profile < ApplicationRecord
extend FriendlyId


+ 2
- 0
app/models/profile/contact_detail.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

##
# Profile::ContactDetail
#

+ 2
- 0
app/view_models/profile/contact_detail_view_model.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class Profile::ContactDetailViewModel
extend Forwardable


+ 2
- 0
bin/rails View File

@@ -1,4 +1,6 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

begin
load File.expand_path('spring', __dir__)
rescue LoadError => e

+ 2
- 0
bin/rake View File

@@ -1,4 +1,6 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

begin
load File.expand_path('spring', __dir__)
rescue LoadError => e

+ 2
- 0
bin/setup View File

@@ -1,4 +1,6 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

require 'fileutils'

# path to your application root.

+ 1
- 0
bin/spring View File

@@ -1,4 +1,5 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

# This file loads Spring without using Bundler, in order to be fast.
# It gets overwritten when you run the `spring binstub` command.

+ 1
- 0
bin/webpack View File

@@ -1,4 +1,5 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

ENV['RAILS_ENV'] ||= ENV['RACK_ENV'] || 'development'
ENV['NODE_ENV'] ||= 'development'

+ 1
- 0
bin/webpack-dev-server View File

@@ -1,4 +1,5 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

ENV['RAILS_ENV'] ||= ENV['RACK_ENV'] || 'development'
ENV['NODE_ENV'] ||= 'development'

+ 2
- 0
bin/yarn View File

@@ -1,4 +1,6 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

APP_ROOT = File.expand_path('..', __dir__)
Dir.chdir(APP_ROOT) do
exec 'yarnpkg', *ARGV

+ 2
- 0
config.ru View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# This file is used by Rack-based servers to start the application.

require_relative 'config/environment'

+ 2
- 0
config/application.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require_relative 'boot'

require 'rails/all'

+ 2
- 0
config/boot.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__)

require 'bundler/setup' # Set up gems listed in the Gemfile.

+ 2
- 0
config/environment.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Load the Rails application.
require_relative 'application'


+ 2
- 0
config/environments/development.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

Rails.application.configure do
# Settings specified here will take precedence over those in config/application.rb.


+ 2
- 0
config/environments/production.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

Rails.application.configure do
# Settings specified here will take precedence over those in config/application.rb.


+ 2
- 0
config/environments/test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# The test environment is used exclusively to run your application's
# test suite. You never need to work with it otherwise. Remember that
# your test database is "scratch space" for the test suite and is wiped

+ 1
- 0
config/initializers/application_controller_renderer.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true
# Be sure to restart your server when you modify this file.

# ActiveSupport::Reloader.to_prepare do

+ 2
- 0
config/initializers/assets.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Be sure to restart your server when you modify this file.

# Version of your assets, change this if you want to expire all your assets.

+ 1
- 0
config/initializers/backtrace_silencers.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true
# Be sure to restart your server when you modify this file.

# You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces.

+ 1
- 0
config/initializers/content_security_policy.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true
# Be sure to restart your server when you modify this file.

# Define an application-wide content security policy

+ 2
- 0
config/initializers/cookies_serializer.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Be sure to restart your server when you modify this file.

# Specify a serializer for the signed and encrypted cookie jars.

+ 2
- 0
config/initializers/filter_parameter_logging.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Be sure to restart your server when you modify this file.

# Configure sensitive parameters which will be filtered from the log file.

+ 2
- 0
config/initializers/friendly_id.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# FriendlyId Global Configuration
#
# Use this to set up shared configuration options for your entire application.

+ 1
- 0
config/initializers/inflections.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true
# Be sure to restart your server when you modify this file.

# Add new inflection rules using the following format. Inflections

+ 2
- 0
config/initializers/mahout_instance.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

module Mahout
# Instance settings
class Application < Rails::Application

+ 1
- 0
config/initializers/mime_types.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true
# Be sure to restart your server when you modify this file.

# Add new mime types for use in respond_to blocks:

+ 2
- 0
config/initializers/wrap_parameters.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Be sure to restart your server when you modify this file.

# This file contains settings for ActionController::ParamsWrapper which

+ 2
- 0
config/puma.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Puma can serve each request in a thread from an internal thread pool.
# The `threads` method setting takes two numbers: a minimum and maximum.
# Any libraries that use thread pools should be configured to match

+ 2
- 0
config/routes.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

Rails.application.routes.draw do
root 'professionals#index'


+ 2
- 0
config/spring.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

Spring.watch(
'.ruby-version',
'.rbenv-vars',

+ 2
- 0
db/migrate/20200410153131_enable_pgcrypto_extension.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class EnablePgcryptoExtension < ActiveRecord::Migration[6.0]
def change
enable_extension 'pgcrypto'

+ 2
- 0
db/migrate/20200410160000_create_profiles.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class CreateProfiles < ActiveRecord::Migration[6.0]
def change
create_table :profiles, id: :uuid do |t|

+ 2
- 0
db/migrate/20200412131932_create_active_storage_tables.active_storage.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# This migration comes from active_storage (originally 20170806125915)
class CreateActiveStorageTables < ActiveRecord::Migration[5.2]
def change

+ 2
- 0
db/migrate/20200413130444_add_last_activity_at_to_profiles.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class AddLastActivityAtToProfiles < ActiveRecord::Migration[6.0]
class Profile < ApplicationRecord
end

+ 2
- 0
db/migrate/20200416094746_add_contact_details_to_profiles.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class AddContactDetailsToProfiles < ActiveRecord::Migration[6.0]
def change
add_column :profiles, :contact_details, :jsonb

+ 2
- 0
db/migrate/20200430111245_add_slug_to_profiles.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

class AddSlugToProfiles < ActiveRecord::Migration[6.0]
def change
add_column :profiles, :slug, :string

+ 2
- 0
db/migrate/20200430111256_create_friendly_id_slugs.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

MIGRATION_CLASS =
if ActiveRecord::VERSION::MAJOR >= 5
ActiveRecord::Migration["#{ActiveRecord::VERSION::MAJOR}.#{ActiveRecord::VERSION::MINOR}"]

+ 2
- 0
db/schema.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.

+ 2
- 0
test/application_system_test_case.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'test_helper'

class ApplicationSystemTestCase < ActionDispatch::SystemTestCase

+ 2
- 0
test/channels/application_cable/connection_test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'test_helper'

class ApplicationCable::ConnectionTest < ActionCable::Connection::TestCase

+ 2
- 0
test/controllers/professionals_controller_test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'test_helper'

class ProfessionalsControllerTest < ActionDispatch::IntegrationTest

+ 2
- 0
test/helpers/public_helper_test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'test_helper'

class PublicHelperTest < ActionView::TestCase

+ 2
- 0
test/models/profile/contact_detail_test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'test_helper'

class Profile::ContactDetailTest < ActiveSupport::TestCase

+ 2
- 0
test/models/profile_test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'test_helper'
require 'minitest/mock'


+ 4
- 0
test/support/workflows.rb View File

@@ -1,2 +1,6 @@
# frozen_string_literal: true

##
# Container for all workflos helpers
module Workflows
end

+ 2
- 0
test/support/workflows/profile_creator.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

module Workflows
# Creates profiles from attributes
class ProfileCreator

+ 2
- 0
test/support/workflows/profile_importer.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

module Workflows
require 'csv'
# Imports profiles from a CSV

+ 2
- 0
test/system/list_professionals_test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'application_system_test_case'

class ListProfessionalsTest < ApplicationSystemTestCase

+ 2
- 0
test/system/view_professional_test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

# As **catalyst of a business network**, when I buy a (trial of) mahout, then I
# can fill it with details from my participants, so that I can showcase my
# participants.

+ 2
- 0
test/view_models/profile/contact_detail_view_model_test.rb View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'test_helper'
require 'minitest/mock'


Loading…
Cancel
Save