diff --git a/.rubocop.yml b/.rubocop.yml index 6b2c027b2f..972e64ad39 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -22,7 +22,7 @@ Lint/ScriptPermission: Exclude: - 'Rakefile' -Metrics/LineLength: +Layout/LineLength: Enabled: false Metrics/BlockLength: @@ -42,7 +42,7 @@ Security/YAMLLoad: - 'db/migrate/*.rb' - 'lib/tasks/ffcrm/config.rake' -StringLiterals: +Style/StringLiterals: Enabled: false Style/Alias: diff --git a/.ruby-version b/.ruby-version index 0aec50e6ed..be94e6f53d 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -3.1.4 +3.2.2 diff --git a/Gemfile b/Gemfile index 2f687f717b..4c48a09e3f 100644 --- a/Gemfile +++ b/Gemfile @@ -7,7 +7,7 @@ source 'https://rubygems.org' case ENV['CI'] && ENV['DB'] when 'sqlite' - gem 'sqlite3', '~> 1.4.0' + gem 'sqlite3', '~> 1.6.8' when 'mysql' gem 'mysql2' when 'postgres' @@ -78,7 +78,7 @@ group :test do gem 'database_cleaner' gem 'zeus', platform: :ruby unless ENV["CI"] gem 'timecop' - gem 'sqlite3', '~> 1.4.0' + gem 'sqlite3', '~> 1.6.8' gem 'webrick' end @@ -87,8 +87,8 @@ group :heroku do gem 'puma' end -gem 'responds_to_parent', git: 'https://github.com/CloCkWeRX/responds_to_parent.git', branch: 'patch-2' # Temporarily pointed at git until https://github.com/zendesk/responds_to_parent/pull/7 is released -gem 'acts_as_commentable', git: 'https://github.com/fatfreecrm/acts_as_commentable.git', branch: 'rails-61' # Our fork +gem 'responds_to_parent', git: 'https://github.com/RedPatchTechnologies/responds_to_parent.git', branch: 'master' # Temporarily pointed at git until https://github.com/zendesk/responds_to_parent/pull/7 is released +gem 'acts_as_commentable', git: 'https://github.com/fatfreecrm/acts_as_commentable.git', branch: 'main' # Our fork gem 'sassc-rails' gem 'coffee-rails' gem 'uglifier' @@ -104,6 +104,6 @@ gem "devise-encryptable" gem 'tzinfo-data', platforms: %i[mingw mswin x64_mingw jruby] gem 'activejob' gem 'ransack_ui' -gem 'bootstrap', '5.0.0' +gem 'bootstrap', '~>5.0.0' gem 'mini_magick' gem 'image_processing', '~> 1.2' diff --git a/Gemfile.lock b/Gemfile.lock index 508149185c..3c4f5147ae 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,85 +1,91 @@ GIT - remote: https://github.com/CloCkWeRX/responds_to_parent.git - revision: b1ab71e59b2d5b0b4351a1b18af9372f517e939e - branch: patch-2 + remote: https://github.com/RedPatchTechnologies/responds_to_parent.git + revision: 36337ac1cb69245bdf551bc852abb9bd77c3826f + branch: master specs: responds_to_parent (2.0.0) - actionpack (>= 3.2.22, < 6.2) + actionpack (>= 3.2.22, < 8.0) GIT remote: https://github.com/fatfreecrm/acts_as_commentable.git - revision: e695ef5a2a8117109cca8e6911e1266d3a37872d - branch: rails-61 + revision: 55516496eefa1c7d109249730b4527e3af236423 + branch: main specs: acts_as_commentable (6.1.0) - activerecord (~> 6.1.0) + activerecord (>= 6.1, < 7.1) GEM remote: https://rubygems.org/ specs: - actioncable (6.1.7.4) - actionpack (= 6.1.7.4) - activesupport (= 6.1.7.4) + actioncable (7.0.8) + actionpack (= 7.0.8) + activesupport (= 7.0.8) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailbox (6.1.7.4) - actionpack (= 6.1.7.4) - activejob (= 6.1.7.4) - activerecord (= 6.1.7.4) - activestorage (= 6.1.7.4) - activesupport (= 6.1.7.4) + actionmailbox (7.0.8) + actionpack (= 7.0.8) + activejob (= 7.0.8) + activerecord (= 7.0.8) + activestorage (= 7.0.8) + activesupport (= 7.0.8) mail (>= 2.7.1) - actionmailer (6.1.7.4) - actionpack (= 6.1.7.4) - actionview (= 6.1.7.4) - activejob (= 6.1.7.4) - activesupport (= 6.1.7.4) + net-imap + net-pop + net-smtp + actionmailer (7.0.8) + actionpack (= 7.0.8) + actionview (= 7.0.8) + activejob (= 7.0.8) + activesupport (= 7.0.8) mail (~> 2.5, >= 2.5.4) + net-imap + net-pop + net-smtp rails-dom-testing (~> 2.0) - actionpack (6.1.7.4) - actionview (= 6.1.7.4) - activesupport (= 6.1.7.4) - rack (~> 2.0, >= 2.0.9) + actionpack (7.0.8) + actionview (= 7.0.8) + activesupport (= 7.0.8) + rack (~> 2.0, >= 2.2.4) rack-test (>= 0.6.3) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.0, >= 1.2.0) - actiontext (6.1.7.4) - actionpack (= 6.1.7.4) - activerecord (= 6.1.7.4) - activestorage (= 6.1.7.4) - activesupport (= 6.1.7.4) + actiontext (7.0.8) + actionpack (= 7.0.8) + activerecord (= 7.0.8) + activestorage (= 7.0.8) + activesupport (= 7.0.8) + globalid (>= 0.6.0) nokogiri (>= 1.8.5) - actionview (6.1.7.4) - activesupport (= 6.1.7.4) + actionview (7.0.8) + activesupport (= 7.0.8) builder (~> 3.1) erubi (~> 1.4) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.1, >= 1.2.0) - activejob (6.1.7.4) - activesupport (= 6.1.7.4) + activejob (7.0.8) + activesupport (= 7.0.8) globalid (>= 0.3.6) - activemodel (6.1.7.4) - activesupport (= 6.1.7.4) + activemodel (7.0.8) + activesupport (= 7.0.8) activemodel-serializers-xml (1.0.2) activemodel (> 5.x) activesupport (> 5.x) builder (~> 3.1) - activerecord (6.1.7.4) - activemodel (= 6.1.7.4) - activesupport (= 6.1.7.4) - activestorage (6.1.7.4) - actionpack (= 6.1.7.4) - activejob (= 6.1.7.4) - activerecord (= 6.1.7.4) - activesupport (= 6.1.7.4) + activerecord (7.0.8) + activemodel (= 7.0.8) + activesupport (= 7.0.8) + activestorage (7.0.8) + actionpack (= 7.0.8) + activejob (= 7.0.8) + activerecord (= 7.0.8) + activesupport (= 7.0.8) marcel (~> 1.0) mini_mime (>= 1.1.0) - activesupport (6.1.7.4) + activesupport (7.0.8) concurrent-ruby (~> 1.0, >= 1.0.2) i18n (>= 1.6, < 2) minitest (>= 5.1) tzinfo (~> 2.0) - zeitwerk (~> 2.3) acts-as-taggable-on (10.0.0) activerecord (>= 6.1, < 7.2) acts_as_list (1.1.0) @@ -89,12 +95,12 @@ GEM airbrussh (1.5.0) sshkit (>= 1.6.1, != 1.7.0) ast (2.4.2) - autoprefixer-rails (10.3.3.0) + autoprefixer-rails (10.4.16.0) execjs (~> 2) - bcrypt (3.1.19) + bcrypt (3.1.20) bootsnap (1.17.0) msgpack (~> 1.2) - bootstrap (5.0.0) + bootstrap (5.0.2) autoprefixer-rails (>= 9.1.0) popper_js (>= 2.9.2, < 3) sassc-rails (>= 2.0.0) @@ -148,7 +154,7 @@ GEM activerecord (>= 5.a) database_cleaner-core (~> 2.0.0) database_cleaner-core (2.0.1) - date (3.3.3) + date (3.3.4) devise (4.9.3) bcrypt (~> 3.0) orm_adapter (~> 0.1) @@ -172,12 +178,12 @@ GEM factory_bot (~> 6.4) railties (>= 5.0.0) ffaker (2.23.0) - ffi (1.15.5) + ffi (1.16.3) font-awesome-rails (4.7.0.8) railties (>= 3.2, < 8.0) formatador (1.1.0) - globalid (1.1.0) - activesupport (>= 5.0) + globalid (1.2.1) + activesupport (>= 6.1) guard (2.18.1) formatador (>= 0.2.4) listen (>= 2.7, < 4.0) @@ -215,6 +221,7 @@ GEM railties (>= 3.2.16) json (2.7.1) language_server-protocol (3.17.0.3) + libv8-node (18.16.0.0-arm64-darwin) libv8-node (18.16.0.0-x86_64-linux) listen (3.8.0) rb-fsevent (~> 0.10, >= 0.10.3) @@ -222,7 +229,7 @@ GEM loofah (2.22.0) crass (~> 1.0.2) nokogiri (>= 1.12.0) - lumberjack (1.2.9) + lumberjack (1.2.10) mail (2.8.1) mini_mime (>= 0.1.1) net-imap @@ -232,22 +239,22 @@ GEM matrix (0.4.2) method_source (1.0.0) mini_magick (4.12.0) - mini_mime (1.1.2) + mini_mime (1.1.5) mini_racer (0.8.0) libv8-node (~> 18.16.0.0) minitest (5.20.0) msgpack (1.7.2) nenv (0.3.0) - net-imap (0.3.6) + net-imap (0.4.6) date net-protocol net-pop (0.1.2) net-protocol - net-protocol (0.2.1) + net-protocol (0.2.2) timeout net-scp (4.0.0) net-ssh (>= 2.6.5, < 8.0.0) - net-smtp (0.3.3) + net-smtp (0.4.0) net-protocol net-ssh (7.2.0) nio4r (2.7.0) @@ -257,7 +264,7 @@ GEM nenv (~> 0.1) shellany (~> 0.0) orm_adapter (0.5.0) - paper_trail (15.0.0) + paper_trail (15.1.0) activerecord (>= 6.1) request_store (~> 1.4) parallel (1.23.0) @@ -265,7 +272,7 @@ GEM ast (~> 2.4.1) racc pg (1.5.4) - popper_js (2.9.3) + popper_js (2.11.8) premailer (1.22.0) addressable css_parser (>= 1.12.0) @@ -282,21 +289,20 @@ GEM rack (2.2.8) rack-test (2.1.0) rack (>= 1.3) - rails (6.1.7.4) - actioncable (= 6.1.7.4) - actionmailbox (= 6.1.7.4) - actionmailer (= 6.1.7.4) - actionpack (= 6.1.7.4) - actiontext (= 6.1.7.4) - actionview (= 6.1.7.4) - activejob (= 6.1.7.4) - activemodel (= 6.1.7.4) - activerecord (= 6.1.7.4) - activestorage (= 6.1.7.4) - activesupport (= 6.1.7.4) + rails (7.0.8) + actioncable (= 7.0.8) + actionmailbox (= 7.0.8) + actionmailer (= 7.0.8) + actionpack (= 7.0.8) + actiontext (= 7.0.8) + actionview (= 7.0.8) + activejob (= 7.0.8) + activemodel (= 7.0.8) + activerecord (= 7.0.8) + activestorage (= 7.0.8) + activesupport (= 7.0.8) bundler (>= 1.15.0) - railties (= 6.1.7.4) - sprockets-rails (>= 2.0.0) + railties (= 7.0.8) rails-controller-testing (1.0.5) actionpack (>= 5.0.1.rc1) actionview (>= 5.0.1.rc1) @@ -318,16 +324,19 @@ GEM rails_12factor (0.0.3) rails_serve_static_assets rails_stdout_logging - rails_autolink (1.1.6) - rails (> 3.1) + rails_autolink (1.1.8) + actionview (> 3.1) + activesupport (> 3.1) + railties (> 3.1) rails_serve_static_assets (0.0.5) rails_stdout_logging (0.0.5) - railties (6.1.7.4) - actionpack (= 6.1.7.4) - activesupport (= 6.1.7.4) + railties (7.0.8) + actionpack (= 7.0.8) + activesupport (= 7.0.8) method_source rake (>= 12.2) thor (~> 1.0) + zeitwerk (~> 2.5) rainbow (3.1.1) rake (13.1.0) ransack (2.6.0) @@ -390,7 +399,7 @@ GEM rubocop-ast (1.30.0) parser (>= 3.2.1.0) ruby-progressbar (1.13.0) - ruby-vips (2.1.4) + ruby-vips (2.2.0) ffi (~> 1.12) rubyzip (2.3.2) sass (3.7.4) @@ -415,22 +424,23 @@ GEM simple_form (5.3.0) actionpack (>= 5.2) activemodel (>= 5.2) - sprockets (4.2.0) + sprockets (4.2.1) concurrent-ruby (~> 1.0) rack (>= 2.2.4, < 4) sprockets-rails (3.4.2) actionpack (>= 5.2) activesupport (>= 5.2) sprockets (>= 3.0.0) - sqlite3 (1.4.4) - sshkit (1.21.5) + sqlite3 (1.6.9-arm64-darwin) + sqlite3 (1.6.9-x86_64-linux) + sshkit (1.21.6) net-scp (>= 1.1.2) net-ssh (>= 2.8.0) temple (0.10.3) thor (1.3.0) tilt (2.3.0) timecop (0.9.8) - timeout (0.4.0) + timeout (0.4.1) tzinfo (2.0.6) concurrent-ruby (~> 1.0) uglifier (4.2.0) @@ -444,8 +454,8 @@ GEM rubyzip (>= 1.3.0) selenium-webdriver (~> 4.0, < 4.11) webrick (1.8.1) - websocket (1.2.9) - websocket-driver (0.7.5) + websocket (1.2.10) + websocket-driver (0.7.6) websocket-extensions (>= 0.1.0) websocket-extensions (0.1.5) will_paginate (4.0.0) @@ -456,6 +466,7 @@ GEM method_source (>= 0.6.7) PLATFORMS + arm64-darwin-22 x86_64-linux DEPENDENCIES @@ -465,7 +476,7 @@ DEPENDENCIES acts_as_commentable! acts_as_list bootsnap - bootstrap (= 5.0.0) + bootstrap (~> 5.0.0) brakeman byebug cancancan (>= 3.3.0) @@ -499,12 +510,12 @@ DEPENDENCIES mini_magick mini_racer nokogiri (>= 1.8.1) - paper_trail (~> 15.0.0) + paper_trail (~> 15.1.0) pg premailer pry-rails puma - rails (~> 6.1.0) + rails (>= 6.1.0, < 7.3.0) rails-controller-testing rails-i18n rails-observers @@ -528,7 +539,7 @@ DEPENDENCIES selenium-webdriver simple_form sprockets-rails (>= 3.0.0) - sqlite3 (~> 1.4.0) + sqlite3 (~> 1.6.8) thor timecop tzinfo-data diff --git a/app/models/setting.rb b/app/models/setting.rb index 1af7299fcc..d5abf1a86c 100644 --- a/app/models/setting.rb +++ b/app/models/setting.rb @@ -62,7 +62,7 @@ def [](name) return cache[name] = setting.value end # Check YAML settings - return cache[name] = yaml_settings[name] if yaml_settings.key?(name) + cache[name] = yaml_settings[name] if yaml_settings.key?(name) end # Set setting value diff --git a/app/models/users/user.rb b/app/models/users/user.rb index 7c634ec60c..df3adf5256 100644 --- a/app/models/users/user.rb +++ b/app/models/users/user.rb @@ -61,7 +61,7 @@ class User < ActiveRecord::Base has_many :opportunities has_many :assigned_opportunities, class_name: 'Opportunity', foreign_key: 'assigned_to' has_many :permissions, dependent: :destroy - has_many :preferences, dependent: :destroy + has_many :preferences, class_name: 'Preference', dependent: :destroy has_many :lists has_and_belongs_to_many :groups diff --git a/bin/bundle b/bin/bundle index 2dbb71769e..4afd75ddef 100755 --- a/bin/bundle +++ b/bin/bundle @@ -1,5 +1,111 @@ #!/usr/bin/env ruby # frozen_string_literal: true -ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__) -load Gem.bin_path('bundler', 'bundle') +# +# This file was generated by Bundler. +# +# The application 'bundle' is installed as part of a gem, and +# this file is here to facilitate running it. +# + +require "rubygems" + +m = Module.new do + module_function + + def invoked_as_script? + File.expand_path($PROGRAM_NAME) == File.expand_path(__FILE__) + end + + def env_var_version + ENV["BUNDLER_VERSION"] + end + + def cli_arg_version + return unless invoked_as_script? # don't want to hijack other binstubs + return unless "update".start_with?(ARGV.first || " ") # must be running `bundle update` + + bundler_version = nil + update_index = nil + ARGV.each_with_index do |a, i| + bundler_version = a if update_index && update_index.succ == i && a =~ Gem::Version::ANCHORED_VERSION_PATTERN + next unless a =~ /\A--bundler(?:[= ](#{Gem::Version::VERSION_PATTERN}))?\z/ + + bundler_version = Regexp.last_match(1) + update_index = i + end + bundler_version + end + + def gemfile + gemfile = ENV["BUNDLE_GEMFILE"] + return gemfile if gemfile && !gemfile.empty? + + File.expand_path("../Gemfile", __dir__) + end + + def lockfile + lockfile = + case File.basename(gemfile) + when "gems.rb" then gemfile.sub(/\.rb$/, ".locked") + else "#{gemfile}.lock" + end + File.expand_path(lockfile) + end + + def lockfile_version + return unless File.file?(lockfile) + + lockfile_contents = File.read(lockfile) + return unless lockfile_contents =~ /\n\nBUNDLED WITH\n\s{2,}(#{Gem::Version::VERSION_PATTERN})\n/ + + Regexp.last_match(1) + end + + def bundler_requirement + @bundler_requirement ||= + env_var_version || + cli_arg_version || + bundler_requirement_for(lockfile_version) + end + + def bundler_requirement_for(version) + return "#{Gem::Requirement.default}.a" unless version + + bundler_gem_version = Gem::Version.new(version) + + bundler_gem_version.approximate_recommendation + end + + def load_bundler! + ENV["BUNDLE_GEMFILE"] ||= gemfile + + activate_bundler + end + + def activate_bundler + gem_error = activation_error_handling do + gem "bundler", bundler_requirement + end + return if gem_error.nil? + + require_error = activation_error_handling do + require "bundler/version" + end + return if require_error.nil? && Gem::Requirement.new(bundler_requirement).satisfied_by?(Gem::Version.new(Bundler::VERSION)) + + warn "Activating bundler (#{bundler_requirement}) failed:\n#{gem_error.message}\n\nTo install the version of bundler this project requires, run `gem install bundler -v '#{bundler_requirement}'`" + exit 42 + end + + def activation_error_handling + yield + nil + rescue StandardError, LoadError => e + e + end +end + +m.load_bundler! + +load Gem.bin_path("bundler", "bundle") if m.invoked_as_script? diff --git a/bin/rails b/bin/rails index a31728ab97..22f2d8deee 100755 --- a/bin/rails +++ b/bin/rails @@ -1,6 +1,6 @@ #!/usr/bin/env ruby # frozen_string_literal: true -APP_PATH = File.expand_path('../config/application', __dir__) -require_relative '../config/boot' -require 'rails/commands' +APP_PATH = File.expand_path("../config/application", __dir__) +require_relative "../config/boot" +require "rails/commands" diff --git a/bin/rake b/bin/rake index c199955006..e436ea54a1 100755 --- a/bin/rake +++ b/bin/rake @@ -1,6 +1,6 @@ #!/usr/bin/env ruby # frozen_string_literal: true -require_relative '../config/boot' -require 'rake' +require_relative "../config/boot" +require "rake" Rake.application.run diff --git a/bin/setup b/bin/setup index ac9f62467c..25fe477540 100755 --- a/bin/setup +++ b/bin/setup @@ -1,38 +1,35 @@ #!/usr/bin/env ruby # frozen_string_literal: true -require 'fileutils' +require "fileutils" # path to your application root. -APP_ROOT = File.expand_path('..', __dir__) +APP_ROOT = File.expand_path("..", __dir__) def system!(*args) system(*args) || abort("\n== Command #{args} failed ==") end FileUtils.chdir APP_ROOT do - # This script is a way to setup or update your development environment automatically. - # This script is idempotent, so that you can run it at anytime and get an expectable outcome. + # This script is a way to set up or update your development environment automatically. + # This script is idempotent, so that you can run it at any time and get an expectable outcome. # Add necessary setup steps to this file. - puts '== Installing dependencies ==' - system! 'gem install bundler --conservative' - system('bundle check') || system!('bundle install') - - # Install JavaScript dependencies - # system('bin/yarn') + puts "== Installing dependencies ==" + system! "gem install bundler --conservative" + system("bundle check") || system!("bundle install") # puts "\n== Copying sample files ==" - # unless File.exist?('config/database.yml') - # FileUtils.cp 'config/database.yml.sample', 'config/database.yml' + # unless File.exist?("config/database.yml") + # FileUtils.cp "config/database.yml.sample", "config/database.yml" # end puts "\n== Preparing database ==" - system! 'bin/rails db:prepare' + system! "bin/rails db:prepare" puts "\n== Removing old logs and tempfiles ==" - system! 'bin/rails log:clear tmp:clear' + system! "bin/rails log:clear tmp:clear" puts "\n== Restarting application server ==" - system! 'bin/rails restart' + system! "bin/rails restart" end diff --git a/config/application.rb b/config/application.rb index 8f7edf745c..0fdd718f57 100644 --- a/config/application.rb +++ b/config/application.rb @@ -30,11 +30,15 @@ module FatFreeCRM class Application < Rails::Application # Initialize configuration defaults for originally generated Rails version. - config.load_defaults 6.0 - - # Settings in config/environments/* take precedence over those specified here. - # Application configuration should go into files in config/initializers - # -- all .rb files in that directory are automatically loaded. + config.load_defaults 7.0 + + # Configuration for the application, engines, and railties goes here. + # + # These settings can be overridden in specific environments using the files + # in config/environments, which are processed later. + # + # config.time_zone = "Central Time (US & Canada)" + # config.eager_load_paths << Rails.root.join("extras") # Models are organized in sub-directories config.autoload_paths += Dir[Rails.root.join("app/models/**")] + diff --git a/config/boot.rb b/config/boot.rb index 783eaee77f..6fb7e9a468 100644 --- a/config/boot.rb +++ b/config/boot.rb @@ -6,9 +6,7 @@ # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php #------------------------------------------------------------------------------ -# Set up gems listed in the Gemfile. -ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__) +ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__) -require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE']) - -require 'bootsnap/setup' +require "bundler/setup" # Set up gems listed in the Gemfile. +require "bootsnap/setup" # Speed up boot time by caching expensive operations. diff --git a/config/cable.yml b/config/cable.yml new file mode 100644 index 0000000000..9a3d0773bb --- /dev/null +++ b/config/cable.yml @@ -0,0 +1,10 @@ +development: + adapter: async + +test: + adapter: test + +production: + adapter: redis + url: <%= ENV.fetch("REDIS_URL") { "redis://localhost:6379/1" } %> + channel_prefix: fat_free_crm_production diff --git a/config/environment.rb b/config/environment.rb index 6d77f556fb..df0861c5fc 100755 --- a/config/environment.rb +++ b/config/environment.rb @@ -5,8 +5,9 @@ # Fat Free CRM is freely distributable under the terms of MIT license. # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php #------------------------------------------------------------------------------ -# Load the rails application -require_relative 'application' -# Initialize the rails application +# Load the Rails application. +require_relative "application" + +# Initialize the Rails application. Rails.application.initialize! diff --git a/config/environments/development.rb b/config/environments/development.rb index 787792dae2..25af9534bc 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -7,35 +7,59 @@ #------------------------------------------------------------------------------ if defined?(FatFreeCRM::Application) FatFreeCRM::Application.configure do - # Settings specified here will take precedence over those in config/application.rb - config.eager_load = false + # Settings specified here will take precedence over those in config/application.rb. - # In the development environment your application's code is reloaded on - # every request. This slows down response time but is perfect for development + # In the development environment your application's code is reloaded any time + # it changes. This slows down response time but is perfect for development # since you don't have to restart the web server when you make code changes. config.cache_classes = false - config.assets.quiet = true + # Do not eager load code on boot. + config.eager_load = false + + # Show full error reports. + config.consider_all_requests_local = true + + # Enable server timing + config.server_timing = true - # Show full error reports and disable caching - config.consider_all_requests_local = true - config.action_controller.perform_caching = false + # Enable/disable caching. By default caching is disabled. + # Run rails dev:cache to toggle caching. + if Rails.root.join("tmp/caching-dev.txt").exist? + config.action_controller.perform_caching = true + config.action_controller.enable_fragment_cache_logging = true + + config.cache_store = :memory_store + config.public_file_server.headers = { + "Cache-Control" => "public, max-age=#{2.days.to_i}" + } + else + config.action_controller.perform_caching = false + + config.cache_store = :null_store + end + + # Store uploaded files on the local file system (see config/storage.yml for options). + config.active_storage.service = :local config.action_mailer.delivery_method = :file config.action_mailer.default_url_options = { host: 'localhost:3000' } - # Don't care if the mailer can't send + # Don't care if the mailer can't send. config.action_mailer.raise_delivery_errors = false - # Print deprecation notices to the Rails logger + # Print deprecation notices to the Rails logger. config.active_support.deprecation = :log # Only use best-standards-support built into browsers # config.action_dispatch.best_standards_support = :builtin - # Raise an error on page load if there are pending migrations + # Raise an error on page load if there are pending migrations. config.active_record.migration_error = :page_load + # Highlight code that triggered database queries in logs. + config.active_record.verbose_query_logs = true + # Expands the lines which load the assets config.assets.debug = true @@ -43,12 +67,21 @@ # yet still be able to expire them through the digest params. config.assets.digest = true + # Suppress logger output for asset requests. + config.assets.quiet = true + + # Raises error for missing translations. + # config.i18n.raise_on_missing_translations = true + + # Annotate rendered view with file names. + # config.action_view.annotate_rendered_view_with_filenames = true + + # Uncomment if you wish to allow Action Cable access from any origin. + # config.action_cable.disable_request_forgery_protection = true + # Adds additional error checking when serving assets at runtime. # Checks for improperly declared sprockets dependencies. # Raises helpful error messages. config.assets.raise_runtime_errors = true - - # Store files locally. - config.active_storage.service = :local end end diff --git a/config/environments/production.rb b/config/environments/production.rb index f8db447e96..fa6efcc5e5 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -7,15 +7,19 @@ #------------------------------------------------------------------------------ if defined?(FatFreeCRM::Application) FatFreeCRM::Application.configure do - # Settings specified here will take precedence over those in config/application.rb - config.eager_load = true + # Settings specified here will take precedence over those in config/application.rb. - # Code is not reloaded between requests + # Code is not reloaded between requests. config.cache_classes = true - # Full error reports are enabled, since this is an internal application. + # Eager load code on boot. This eager loads most of Rails and + # your application in memory, allowing both threaded web servers + # and those relying on copy on write to perform better. + # Rake tasks automatically ignore this option for performance. + config.eager_load = true + + # Full error reports are disabled and caching is turned on. config.consider_all_requests_local = false - # Caching is turned on config.action_controller.perform_caching = true # Disable Rails's static asset server (Apache or nginx will already do this) @@ -24,29 +28,27 @@ # Compress JavaScripts and CSS config.assets.compress = true - # Don't fallback to assets pipeline if a precompiled asset is missed + # Do not fallback to assets pipeline if a precompiled asset is missed. config.assets.compile = false # Generate digests for assets URLs config.assets.digest = true - # Defaults to Rails.root.join("public/assets") - # config.assets.manifest = YOUR_PATH - - # Specifies the header that your server uses for sending files - # config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache - # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx + # Specifies the header that your server uses for sending files. + # config.action_dispatch.x_sendfile_header = "X-Sendfile" # for Apache + # config.action_dispatch.x_sendfile_header = "X-Accel-Redirect" # for NGINX # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies. # config.force_ssl = true - # See everything in the log (default is :info) + # Include generic and useful information about system operation, but avoid logging too much + # information to avoid inadvertent exposure of personally identifiable information (PII). config.log_level = :info # Use a different logger for distributed setups # config.logger = SyslogLogger.new - # Use a different cache store in production + # Use a different cache store in production. # config.cache_store = :mem_cache_store # Enable serving of images, stylesheets, and JavaScripts from an asset server @@ -56,7 +58,7 @@ # config.assets.precompile += %w( search.js ) # Enable locale fallbacks for I18n (makes lookups for any locale fall back to - # the I18n.default_locale when a translation can not be found) + # the I18n.default_locale when a translation cannot be found). config.i18n.fallbacks = true # Send deprecation notices to registered listeners diff --git a/config/environments/test.rb b/config/environments/test.rb index 9abc693c2e..b08f8ebfb1 100755 --- a/config/environments/test.rb +++ b/config/environments/test.rb @@ -7,29 +7,33 @@ #------------------------------------------------------------------------------ if defined?(FatFreeCRM::Application) FatFreeCRM::Application.configure do + # Settings specified here will take precedence over those in config/application.rb. + # 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 # and recreated between test runs. Don't rely on the data there! + # Turn false under Spring and add config.action_view.cache_template_loading = true. config.cache_classes = true - # Do not eager load code on boot. This avoids loading your whole application - # just for the purpose of running a single test. If you are using a tool that - # preloads Rails for running tests, you may have to set it to true. - config.eager_load = false + # Eager loading loads your whole application. When running a single test locally, + # this probably isn't necessary. It's a good idea to do in a continuous integration + # system, or in some way before deploying your code. + config.eager_load = ENV["CI"].present? - # Configure static file server for tests with Cache-Control for performance. + # Configure public file server for tests with Cache-Control for performance. config.public_file_server.enabled = true config.public_file_server.headers = { 'Cache-Control' => 'public, max-age=3600' } - # Show full error reports and disable caching + # Show full error reports and disable caching. config.consider_all_requests_local = true config.action_controller.perform_caching = false + config.cache_store = :null_store - # Raise exceptions instead of rendering exception templates + # Raise exceptions instead of rendering exception templates. config.action_dispatch.show_exceptions = false - # Disable request forgery protection in test environment + # Disable request forgery protection in test environment. config.action_controller.allow_forgery_protection = false # Tell Action Mailer not to deliver emails to the real world. @@ -43,7 +47,7 @@ # Randomize the order test cases are executed. config.active_support.test_order = :random - # Print deprecation notices to the stderr + # Print deprecation notices to the stderr. config.active_support.deprecation = :stderr # Store uploaded files on the local file system in a temporary directory @@ -52,6 +56,12 @@ config.action_mailer.perform_caching = false # Raises error for missing translations # config.action_view.raise_on_missing_translations = true + + # Raises error for missing translations. + # config.i18n.raise_on_missing_translations = true + + # Annotate rendered view with file names. + # config.action_view.annotate_rendered_view_with_filenames = true end # Optionally load 'awesome_print' for debugging in development mode. diff --git a/config/initializers/action_mailer.rb b/config/initializers/action_mailer.rb index b6a5b79f2b..f049d9c035 100644 --- a/config/initializers/action_mailer.rb +++ b/config/initializers/action_mailer.rb @@ -10,6 +10,7 @@ # ActionMailer is setup in test mode later on # unless Rails.env.test? + require './app/models/setting' smtp_settings = Setting.smtp || {} diff --git a/config/initializers/content_security_policy.rb b/config/initializers/content_security_policy.rb index f3bcce5465..691cfa11a6 100644 --- a/config/initializers/content_security_policy.rb +++ b/config/initializers/content_security_policy.rb @@ -1,31 +1,26 @@ # frozen_string_literal: true # Be sure to restart your server when you modify this file. -# Define an application-wide content security policy -# For further information see the following documentation -# https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy +# Define an application-wide content security policy. +# See the Securing Rails Applications Guide for more information: +# https://guides.rubyonrails.org/security.html#content-security-policy-header -# Rails.application.config.content_security_policy do |policy| -# policy.default_src :self, :https -# policy.font_src :self, :https, :data -# policy.img_src :self, :https, :data -# policy.object_src :none -# policy.script_src :self, :https -# policy.style_src :self, :https -# # If you are using webpack-dev-server then specify webpack-dev-server host -# policy.connect_src :self, :https, "http://localhost:3035", "ws://localhost:3035" if Rails.env.development? - -# # Specify URI for violation reports -# # policy.report_uri "/csp-violation-report-endpoint" +# Rails.application.configure do +# config.content_security_policy do |policy| +# policy.default_src :self, :https +# policy.font_src :self, :https, :data +# policy.img_src :self, :https, :data +# policy.object_src :none +# policy.script_src :self, :https +# policy.style_src :self, :https +# # Specify URI for violation reports +# # policy.report_uri "/csp-violation-report-endpoint" +# end +# +# # Generate session nonces for permitted importmap and inline scripts +# config.content_security_policy_nonce_generator = ->(request) { request.session.id.to_s } +# config.content_security_policy_nonce_directives = %w(script-src) +# +# # Report violations without enforcing the policy. +# # config.content_security_policy_report_only = true # end - -# If you are using UJS then enable automatic nonce generation -# Rails.application.config.content_security_policy_nonce_generator = -> request { SecureRandom.base64(16) } - -# Set the nonce only to specific directives -# Rails.application.config.content_security_policy_nonce_directives = %w(script-src) - -# Report CSP violations to a specified URI -# For further information see the following documentation: -# https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy-Report-Only -# Rails.application.config.content_security_policy_report_only = true diff --git a/config/initializers/custom_field_ransack_translations.rb b/config/initializers/custom_field_ransack_translations.rb index f601a36116..dfb95aa5ba 100644 --- a/config/initializers/custom_field_ransack_translations.rb +++ b/config/initializers/custom_field_ransack_translations.rb @@ -6,6 +6,7 @@ # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php #------------------------------------------------------------------------------ # Load field names for custom fields, for Ransack search +require './app/models/setting' if Setting.database_and_table_exists? Rails.application.config.after_initialize do I18n.backend.load_translations diff --git a/config/initializers/filter_parameter_logging.rb b/config/initializers/filter_parameter_logging.rb index 7a4f47b4c2..3df77c5bee 100644 --- a/config/initializers/filter_parameter_logging.rb +++ b/config/initializers/filter_parameter_logging.rb @@ -2,5 +2,9 @@ # Be sure to restart your server when you modify this file. -# Configure sensitive parameters which will be filtered from the log file. -Rails.application.config.filter_parameters += [:password] +# Configure parameters to be filtered from the log file. Use this to limit dissemination of +# sensitive information. See the ActiveSupport::ParameterFilter documentation for supported +# notations and behaviors. +Rails.application.config.filter_parameters += %i[ + passw secret token _key crypt salt certificate otp ssn +] diff --git a/config/initializers/inflections.rb b/config/initializers/inflections.rb index aa7435fbc9..6c78420e71 100644 --- a/config/initializers/inflections.rb +++ b/config/initializers/inflections.rb @@ -5,13 +5,13 @@ # are locale specific, and you may define rules for as many different # locales as you wish. All of these examples are active by default: # ActiveSupport::Inflector.inflections(:en) do |inflect| -# inflect.plural /^(ox)$/i, '\1en' -# inflect.singular /^(ox)en/i, '\1' -# inflect.irregular 'person', 'people' +# inflect.plural /^(ox)$/i, "\\1en" +# inflect.singular /^(ox)en/i, "\\1" +# inflect.irregular "person", "people" # inflect.uncountable %w( fish sheep ) # end # These inflection rules are supported but not enabled by default: # ActiveSupport::Inflector.inflections(:en) do |inflect| -# inflect.acronym 'RESTful' +# inflect.acronym "RESTful" # end diff --git a/config/initializers/new_framework_defaults_6_0.rb b/config/initializers/new_framework_defaults_6_0.rb deleted file mode 100644 index a48d4eb00f..0000000000 --- a/config/initializers/new_framework_defaults_6_0.rb +++ /dev/null @@ -1,46 +0,0 @@ -# frozen_string_literal: true -# Be sure to restart your server when you modify this file. -# -# This file contains migration options to ease your Rails 6.0 upgrade. -# -# Once upgraded flip defaults one by one to migrate to the new default. -# -# Read the Guide for Upgrading Ruby on Rails for more info on each option. - -# Don't force requests from old versions of IE to be UTF-8 encoded. -# Rails.application.config.action_view.default_enforce_utf8 = false - -# Embed purpose and expiry metadata inside signed and encrypted -# cookies for increased security. -# -# This option is not backwards compatible with earlier Rails versions. -# It's best enabled when your entire app is migrated and stable on 6.0. -# Rails.application.config.action_dispatch.use_cookies_with_metadata = true - -# Change the return value of `ActionDispatch::Response#content_type` to Content-Type header without modification. -# Rails.application.config.action_dispatch.return_only_media_type_on_content_type = false - -# Return false instead of self when enqueuing is aborted from a callback. -# Rails.application.config.active_job.return_false_on_aborted_enqueue = true - -# Send Active Storage analysis and purge jobs to dedicated queues. -# Rails.application.config.active_storage.queues.analysis = :active_storage_analysis -# Rails.application.config.active_storage.queues.purge = :active_storage_purge - -# When assigning to a collection of attachments declared via `has_many_attached`, replace existing -# attachments instead of appending. Use #attach to add new attachments without replacing existing ones. -# Rails.application.config.active_storage.replace_on_assign_to_many = true - -# Use ActionMailer::MailDeliveryJob for sending parameterized and normal mail. -# -# The default delivery jobs (ActionMailer::Parameterized::DeliveryJob, ActionMailer::DeliveryJob), -# will be removed in Rails 6.1. This setting is not backwards compatible with earlier Rails versions. -# If you send mail in the background, job workers need to have a copy of -# MailDeliveryJob to ensure all delivery jobs are processed properly. -# Make sure your entire app is migrated and stable on 6.0 before using this setting. -# Rails.application.config.action_mailer.delivery_job = "ActionMailer::MailDeliveryJob" - -# Enable the same cache key to be reused when the object being cached of type -# `ActiveRecord::Relation` changes by moving the volatile information (max updated at and count) -# of the relation's cache key into the cache version to support recycling cache key. -# Rails.application.config.active_record.collection_cache_versioning = true diff --git a/config/initializers/permissions_policy.rb b/config/initializers/permissions_policy.rb new file mode 100644 index 0000000000..50bcf4eade --- /dev/null +++ b/config/initializers/permissions_policy.rb @@ -0,0 +1,12 @@ +# frozen_string_literal: true +# Define an application-wide HTTP permissions policy. For further +# information see https://developers.google.com/web/updates/2018/06/feature-policy +# +# Rails.application.config.permissions_policy do |f| +# f.camera :none +# f.gyroscope :none +# f.microphone :none +# f.usb :none +# f.fullscreen :self +# f.payment :self, "https://secure.example.com" +# end diff --git a/config/storage.yml b/config/storage.yml index d32f76e8fb..4942ab6694 100644 --- a/config/storage.yml +++ b/config/storage.yml @@ -6,27 +6,27 @@ local: service: Disk root: <%= Rails.root.join("storage") %> -# Use rails credentials:edit to set the AWS secrets (as aws:access_key_id|secret_access_key) +# Use bin/rails credentials:edit to set the AWS secrets (as aws:access_key_id|secret_access_key) # amazon: # service: S3 # access_key_id: <%= Rails.application.credentials.dig(:aws, :access_key_id) %> # secret_access_key: <%= Rails.application.credentials.dig(:aws, :secret_access_key) %> # region: us-east-1 -# bucket: your_own_bucket +# bucket: your_own_bucket-<%= Rails.env %> # Remember not to checkin your GCS keyfile to a repository # google: # service: GCS # project: your_project # credentials: <%= Rails.root.join("path/to/gcs.keyfile") %> -# bucket: your_own_bucket +# bucket: your_own_bucket-<%= Rails.env %> -# Use rails credentials:edit to set the Azure Storage secret (as azure_storage:storage_access_key) +# Use bin/rails credentials:edit to set the Azure Storage secret (as azure_storage:storage_access_key) # microsoft: # service: AzureStorage # storage_account_name: your_account_name # storage_access_key: <%= Rails.application.credentials.dig(:azure_storage, :storage_access_key) %> -# container: your_container_name +# container: your_container_name-<%= Rails.env %> # mirror: # service: Mirror diff --git a/db/schema.rb b/db/schema.rb index 5472b66f0f..07627cb69f 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -10,27 +10,29 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 2023_05_26_212613) do +ActiveRecord::Schema[7.0].define(version: 2023_05_26_212613) do + # These are extensions that must be enabled in order to support this database + enable_extension "plpgsql" - create_table "account_contacts", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "account_contacts", force: :cascade do |t| t.integer "account_id" t.integer "contact_id" - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.index ["account_id", "contact_id"], name: "index_account_contacts_on_account_id_and_contact_id" end - create_table "account_opportunities", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "account_opportunities", force: :cascade do |t| t.integer "account_id" t.integer "opportunity_id" - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.index ["account_id", "opportunity_id"], name: "index_account_opportunities_on_account_id_and_opportunity_id" end - create_table "accounts", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "accounts", force: :cascade do |t| t.integer "user_id" t.integer "assigned_to" t.string "name", limit: 64, default: "", null: false @@ -39,9 +41,9 @@ t.string "toll_free_phone", limit: 32 t.string "phone", limit: 32 t.string "fax", limit: 32 - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.string "email", limit: 254 t.string "background_info" t.integer "rating", default: 0, null: false @@ -53,17 +55,17 @@ t.index ["user_id", "name", "deleted_at"], name: "index_accounts_on_user_id_and_name_and_deleted_at", unique: true end - create_table "active_storage_attachments", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "active_storage_attachments", force: :cascade do |t| t.string "name", null: false t.string "record_type", null: false t.bigint "record_id", null: false t.bigint "blob_id", null: false - t.datetime "created_at", null: false + t.datetime "created_at", precision: nil, null: false t.index ["blob_id"], name: "index_active_storage_attachments_on_blob_id" t.index ["record_type", "record_id", "name", "blob_id"], name: "index_active_storage_attachments_uniqueness", unique: true end - create_table "active_storage_blobs", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "active_storage_blobs", force: :cascade do |t| t.string "key", null: false t.string "filename", null: false t.string "content_type" @@ -71,30 +73,30 @@ t.string "service_name", null: false t.bigint "byte_size", null: false t.string "checksum", null: false - t.datetime "created_at", null: false + t.datetime "created_at", precision: nil, null: false t.index ["key"], name: "index_active_storage_blobs_on_key", unique: true end - create_table "active_storage_variant_records", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "active_storage_variant_records", force: :cascade do |t| t.bigint "blob_id", null: false t.string "variation_digest", null: false t.index ["blob_id", "variation_digest"], name: "index_active_storage_variant_records_uniqueness", unique: true end - create_table "activities", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "activities", force: :cascade do |t| t.integer "user_id" t.string "subject_type" t.integer "subject_id" t.string "action", limit: 32, default: "created" t.string "info", default: "" t.boolean "private", default: false - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.index ["created_at"], name: "index_activities_on_created_at" t.index ["user_id"], name: "index_activities_on_user_id" end - create_table "addresses", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "addresses", force: :cascade do |t| t.string "street1" t.string "street2" t.string "city", limit: 64 @@ -105,24 +107,24 @@ t.string "address_type", limit: 16 t.string "addressable_type" t.integer "addressable_id" - t.datetime "created_at" - t.datetime "updated_at" - t.datetime "deleted_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil + t.datetime "deleted_at", precision: nil t.index ["addressable_id", "addressable_type"], name: "index_addresses_on_addressable_id_and_addressable_type" end - create_table "avatars", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "avatars", force: :cascade do |t| t.integer "user_id" t.string "entity_type" t.integer "entity_id" t.integer "image_file_size" t.string "image_file_name" t.string "image_content_type" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil end - create_table "campaigns", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "campaigns", force: :cascade do |t| t.integer "user_id" t.integer "assigned_to" t.string "name", limit: 64, default: "", null: false @@ -138,38 +140,38 @@ t.date "starts_on" t.date "ends_on" t.text "objectives" - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.string "background_info" t.text "subscribed_users" t.index ["assigned_to"], name: "index_campaigns_on_assigned_to" t.index ["user_id", "name", "deleted_at"], name: "index_campaigns_on_user_id_and_name_and_deleted_at", unique: true end - create_table "comments", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "comments", force: :cascade do |t| t.integer "user_id" t.string "commentable_type" t.integer "commentable_id" t.boolean "private" t.string "title", default: "" t.text "comment" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.string "state", limit: 16, default: "Expanded", null: false end - create_table "contact_opportunities", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "contact_opportunities", force: :cascade do |t| t.integer "contact_id" t.integer "opportunity_id" t.string "role", limit: 32 - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.index ["contact_id", "opportunity_id"], name: "index_contact_opportunities_on_contact_id_and_opportunity_id" end - create_table "contacts", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "contacts", force: :cascade do |t| t.integer "user_id" t.integer "lead_id" t.integer "assigned_to" @@ -191,9 +193,9 @@ t.string "twitter", limit: 128 t.date "born_on" t.boolean "do_not_call", default: false, null: false - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.string "background_info" t.string "skype", limit: 128 t.text "subscribed_users" @@ -201,7 +203,7 @@ t.index ["user_id", "last_name", "deleted_at"], name: "id_last_name_deleted", unique: true end - create_table "emails", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "emails", force: :cascade do |t| t.string "imap_message_id", null: false t.integer "user_id" t.string "mediator_type" @@ -213,27 +215,27 @@ t.string "subject" t.text "body" t.text "header" - t.datetime "sent_at" - t.datetime "received_at" - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "sent_at", precision: nil + t.datetime "received_at", precision: nil + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.string "state", limit: 16, default: "Expanded", null: false t.index ["mediator_id", "mediator_type"], name: "index_emails_on_mediator_id_and_mediator_type" end - create_table "field_groups", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "field_groups", force: :cascade do |t| t.string "name", limit: 64 t.string "label", limit: 128 t.integer "position" t.string "hint" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.integer "tag_id" t.string "klass_name", limit: 32 end - create_table "fields", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "fields", force: :cascade do |t| t.string "type" t.integer "field_group_id" t.integer "position" @@ -246,8 +248,8 @@ t.boolean "disabled" t.boolean "required" t.integer "maxlength" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.integer "pair_id" t.text "settings" t.integer "minlength", default: 0 @@ -260,13 +262,13 @@ t.index ["name"], name: "index_fields_on_name" end - create_table "groups", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "groups", force: :cascade do |t| t.string "name" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil end - create_table "groups_users", id: false, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "groups_users", id: false, force: :cascade do |t| t.integer "group_id" t.integer "user_id" t.index ["group_id", "user_id"], name: "index_groups_users_on_group_id_and_user_id" @@ -274,7 +276,7 @@ t.index ["user_id"], name: "index_groups_users_on_user_id" end - create_table "leads", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "leads", force: :cascade do |t| t.integer "user_id" t.integer "campaign_id" t.integer "assigned_to" @@ -296,9 +298,9 @@ t.string "twitter", limit: 128 t.integer "rating", default: 0, null: false t.boolean "do_not_call", default: false, null: false - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.string "background_info" t.string "skype", limit: 128 t.text "subscribed_users" @@ -306,16 +308,16 @@ t.index ["user_id", "last_name", "deleted_at"], name: "index_leads_on_user_id_and_last_name_and_deleted_at", unique: true end - create_table "lists", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "lists", force: :cascade do |t| t.string "name" t.text "url" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.integer "user_id" t.index ["user_id"], name: "index_lists_on_user_id" end - create_table "opportunities", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "opportunities", force: :cascade do |t| t.integer "user_id" t.integer "campaign_id" t.integer "assigned_to" @@ -327,72 +329,72 @@ t.decimal "amount", precision: 12, scale: 2 t.decimal "discount", precision: 12, scale: 2 t.date "closes_on" - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.string "background_info" t.text "subscribed_users" t.index ["assigned_to"], name: "index_opportunities_on_assigned_to" t.index ["user_id", "name", "deleted_at"], name: "id_name_deleted", unique: true end - create_table "permissions", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "permissions", force: :cascade do |t| t.integer "user_id" t.string "asset_type" t.integer "asset_id" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.integer "group_id" t.index ["asset_id", "asset_type"], name: "index_permissions_on_asset_id_and_asset_type" t.index ["group_id"], name: "index_permissions_on_group_id" t.index ["user_id"], name: "index_permissions_on_user_id" end - create_table "preferences", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "preferences", force: :cascade do |t| t.integer "user_id" t.string "name", limit: 32, default: "", null: false t.text "value" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.index ["user_id", "name"], name: "index_preferences_on_user_id_and_name" end - create_table "sessions", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "sessions", force: :cascade do |t| t.string "session_id", null: false t.text "data" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.index ["session_id"], name: "index_sessions_on_session_id" t.index ["updated_at"], name: "index_sessions_on_updated_at" end - create_table "settings", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "settings", force: :cascade do |t| t.string "name", limit: 32, default: "", null: false t.text "value" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.index ["name"], name: "index_settings_on_name" end - create_table "taggings", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "taggings", force: :cascade do |t| t.integer "tag_id" t.integer "taggable_id" t.integer "tagger_id" t.string "tagger_type" t.string "taggable_type", limit: 50 t.string "context", limit: 50 - t.datetime "created_at" + t.datetime "created_at", precision: nil t.index ["tag_id", "taggable_id", "taggable_type", "context"], name: "taggings_idx", unique: true t.index ["taggable_id", "taggable_type", "context"], name: "index_taggings_on_taggable_id_and_taggable_type_and_context" end - create_table "tags", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "tags", force: :cascade do |t| t.string "name" t.integer "taggings_count", default: 0 t.index ["name"], name: "index_tags_on_name", unique: true end - create_table "tasks", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "tasks", force: :cascade do |t| t.integer "user_id" t.integer "assigned_to" t.integer "completed_by" @@ -402,18 +404,18 @@ t.string "priority", limit: 32 t.string "category", limit: 32 t.string "bucket", limit: 32 - t.datetime "due_at" - t.datetime "completed_at" - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "due_at", precision: nil + t.datetime "completed_at", precision: nil + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.string "background_info" t.text "subscribed_users" t.index ["assigned_to"], name: "index_tasks_on_assigned_to" t.index ["user_id", "name", "deleted_at"], name: "index_tasks_on_user_id_and_name_and_deleted_at", unique: true end - create_table "users", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "users", force: :cascade do |t| t.string "username", limit: 32, default: "", null: false t.string "email", limit: 254, default: "", null: false t.string "first_name", limit: 32 @@ -429,25 +431,25 @@ t.string "skype", limit: 32 t.string "encrypted_password", default: "", null: false t.string "password_salt", default: "", null: false - t.datetime "last_sign_in_at" - t.datetime "current_sign_in_at" + t.datetime "last_sign_in_at", precision: nil + t.datetime "current_sign_in_at", precision: nil t.string "last_sign_in_ip" t.string "current_sign_in_ip" t.integer "sign_in_count", default: 0, null: false - t.datetime "deleted_at" - t.datetime "created_at" - t.datetime "updated_at" + t.datetime "deleted_at", precision: nil + t.datetime "created_at", precision: nil + t.datetime "updated_at", precision: nil t.boolean "admin", default: false, null: false - t.datetime "suspended_at" + t.datetime "suspended_at", precision: nil t.string "unconfirmed_email", limit: 254 t.string "reset_password_token" - t.datetime "reset_password_sent_at" + t.datetime "reset_password_sent_at", precision: nil t.string "remember_token" - t.datetime "remember_created_at" + t.datetime "remember_created_at", precision: nil t.string "authentication_token" - t.string "confirmation_token" - t.timestamp "confirmed_at" - t.timestamp "confirmation_sent_at" + t.string "confirmation_token", limit: 255 + t.datetime "confirmed_at", precision: nil + t.datetime "confirmation_sent_at", precision: nil t.index ["authentication_token"], name: "index_users_on_authentication_token", unique: true t.index ["confirmation_token"], name: "index_users_on_confirmation_token", unique: true t.index ["email"], name: "index_users_on_email" @@ -456,13 +458,13 @@ t.index ["username", "deleted_at"], name: "index_users_on_username_and_deleted_at", unique: true end - create_table "versions", id: :integer, charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| + create_table "versions", force: :cascade do |t| t.string "item_type", null: false t.integer "item_id", null: false t.string "event", limit: 512, null: false t.string "whodunnit" t.text "object" - t.datetime "created_at" + t.datetime "created_at", precision: nil t.text "object_changes" t.integer "related_id" t.string "related_type" diff --git a/fat_free_crm.gemspec b/fat_free_crm.gemspec index 8fccf26c1a..eac95846e7 100755 --- a/fat_free_crm.gemspec +++ b/fat_free_crm.gemspec @@ -15,7 +15,7 @@ Gem::Specification.new do |gem| gem.required_ruby_version = '>= 3.1' gem.license = 'MIT' - gem.add_dependency 'rails', '~> 6.1.0' + gem.add_dependency 'rails', '>= 6.1.0', '< 7.3.0' gem.add_dependency 'rails-i18n' gem.add_dependency 'rails-observers' gem.add_dependency 'activemodel-serializers-xml' @@ -27,7 +27,7 @@ Gem::Specification.new do |gem| gem.add_dependency 'select2-rails' gem.add_dependency 'simple_form' gem.add_dependency 'will_paginate' - gem.add_dependency 'paper_trail', '~> 15.0.0' + gem.add_dependency 'paper_trail', '~> 15.1.0' gem.add_dependency 'devise', '~> 4.6' gem.add_dependency 'devise-encryptable', '~> 0.2.0' gem.add_dependency 'acts_as_commentable', '>= 6.1' diff --git a/spec/lib/mail_processor/dropbox_spec.rb b/spec/lib/mail_processor/dropbox_spec.rb index 7d142e76e5..bf47481b92 100644 --- a/spec/lib/mail_processor/dropbox_spec.rb +++ b/spec/lib/mail_processor/dropbox_spec.rb @@ -184,15 +184,15 @@ it "should touch the asset" do now = Time.zone.now - timezone = ActiveRecord::Base.default_timezone + timezone = ActiveRecord.default_timezone begin - ActiveRecord::Base.default_timezone = :utc + ActiveRecord.default_timezone = :utc @lead = create(:lead, email: "ben@example.com", access: "Public", updated_at: 5.day.ago) @crawler.run expect(@lead.reload.updated_at.to_i).to be >= now.to_i ensure - ActiveRecord::Base.default_timezone = timezone + ActiveRecord.default_timezone = timezone end end diff --git a/spec/views/accounts/_edit.haml_spec.rb b/spec/views/accounts/_edit.haml_spec.rb index 88aeef2294..4fefcf4249 100644 --- a/spec/views/accounts/_edit.haml_spec.rb +++ b/spec/views/accounts/_edit.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/accounts/_edit" do +describe "accounts/_edit" do include AccountsHelper before do diff --git a/spec/views/accounts/_new.haml_spec.rb b/spec/views/accounts/_new.haml_spec.rb index 22f2d868a4..5371b12457 100644 --- a/spec/views/accounts/_new.haml_spec.rb +++ b/spec/views/accounts/_new.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/accounts/_new" do +describe "accounts/_new" do include AccountsHelper before do diff --git a/spec/views/accounts/create.js.haml_spec.rb b/spec/views/accounts/create.js.haml_spec.rb index d2a35f669d..47f3e4d0fb 100644 --- a/spec/views/accounts/create.js.haml_spec.rb +++ b/spec/views/accounts/create.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/accounts/create" do +describe "accounts/create" do include AccountsHelper before do diff --git a/spec/views/accounts/destroy.js.haml_spec.rb b/spec/views/accounts/destroy.js.haml_spec.rb index ea6d32d3b3..444063d752 100644 --- a/spec/views/accounts/destroy.js.haml_spec.rb +++ b/spec/views/accounts/destroy.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/accounts/destroy" do +describe "accounts/destroy" do include AccountsHelper before do diff --git a/spec/views/accounts/edit.js.haml_spec.rb b/spec/views/accounts/edit.js.haml_spec.rb index a3d6030599..994b90eb27 100644 --- a/spec/views/accounts/edit.js.haml_spec.rb +++ b/spec/views/accounts/edit.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/accounts/edit" do +describe "accounts/edit" do include AccountsHelper before do diff --git a/spec/views/accounts/index.haml_spec.rb b/spec/views/accounts/index.haml_spec.rb index c96a838a26..a76559bc7b 100644 --- a/spec/views/accounts/index.haml_spec.rb +++ b/spec/views/accounts/index.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/accounts/index" do +describe "accounts/index" do include AccountsHelper before do diff --git a/spec/views/accounts/index.js.haml_spec.rb b/spec/views/accounts/index.js.haml_spec.rb index 03734f80b2..60853ec415 100644 --- a/spec/views/accounts/index.js.haml_spec.rb +++ b/spec/views/accounts/index.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/accounts/index" do +describe "accounts/index" do include AccountsHelper before do diff --git a/spec/views/accounts/new.js.haml_spec.rb b/spec/views/accounts/new.js.haml_spec.rb index 901d25b0d2..1e399e7d70 100644 --- a/spec/views/accounts/new.js.haml_spec.rb +++ b/spec/views/accounts/new.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/accounts/new" do +describe "accounts/new" do include AccountsHelper before do diff --git a/spec/views/accounts/show.haml_spec.rb b/spec/views/accounts/show.haml_spec.rb index 19c17c4953..f25381f51e 100644 --- a/spec/views/accounts/show.haml_spec.rb +++ b/spec/views/accounts/show.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/accounts/show" do +describe "accounts/show" do include AccountsHelper before do diff --git a/spec/views/accounts/update.js.haml_spec.rb b/spec/views/accounts/update.js.haml_spec.rb index e71a856279..de98d5f4f4 100644 --- a/spec/views/accounts/update.js.haml_spec.rb +++ b/spec/views/accounts/update.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/accounts/update" do +describe "accounts/update" do include AccountsHelper before do diff --git a/spec/views/admin/users/index.haml_spec.rb b/spec/views/admin/users/index.haml_spec.rb index 85d934e989..90ae7bad07 100755 --- a/spec/views/admin/users/index.haml_spec.rb +++ b/spec/views/admin/users/index.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../../spec_helper') -describe "/admin/users/index" do +describe "admin/users/index" do before do login_admin end diff --git a/spec/views/admin/users/show.haml_spec.rb b/spec/views/admin/users/show.haml_spec.rb index 289620eb48..91c4dd1518 100755 --- a/spec/views/admin/users/show.haml_spec.rb +++ b/spec/views/admin/users/show.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../../spec_helper') -describe "/admin/users/show" do +describe "admin/users/show" do before do assign(:user, @user = stub_model(User)) end diff --git a/spec/views/application/auto_complete.haml_spec.rb b/spec/views/application/auto_complete.haml_spec.rb index f0ba9920f7..887ead0d0c 100644 --- a/spec/views/application/auto_complete.haml_spec.rb +++ b/spec/views/application/auto_complete.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/application/_auto_complete" do +describe "application/_auto_complete" do include AccountsHelper before do diff --git a/spec/views/campaigns/_edit.haml_spec.rb b/spec/views/campaigns/_edit.haml_spec.rb index 3c4b8c6413..3b97df0233 100644 --- a/spec/views/campaigns/_edit.haml_spec.rb +++ b/spec/views/campaigns/_edit.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/campaigns/_edit" do +describe "campaigns/_edit" do include CampaignsHelper before do diff --git a/spec/views/campaigns/_new.haml_spec.rb b/spec/views/campaigns/_new.haml_spec.rb index a1074700e5..bc3cd71b33 100644 --- a/spec/views/campaigns/_new.haml_spec.rb +++ b/spec/views/campaigns/_new.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/campaigns/_new" do +describe "campaigns/_new" do include CampaignsHelper before do diff --git a/spec/views/campaigns/create.js.haml_spec.rb b/spec/views/campaigns/create.js.haml_spec.rb index 3938abfd24..024c938ddc 100755 --- a/spec/views/campaigns/create.js.haml_spec.rb +++ b/spec/views/campaigns/create.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/campaigns/create" do +describe "campaigns/create" do before do login end diff --git a/spec/views/campaigns/destroy.js.haml_spec.rb b/spec/views/campaigns/destroy.js.haml_spec.rb index 5c8a568b6b..b55be51721 100755 --- a/spec/views/campaigns/destroy.js.haml_spec.rb +++ b/spec/views/campaigns/destroy.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/campaigns/destroy" do +describe "campaigns/destroy" do before do login assign(:campaign, @campaign = build_stubbed(:campaign, user: current_user)) diff --git a/spec/views/campaigns/edit.js.haml_spec.rb b/spec/views/campaigns/edit.js.haml_spec.rb index b9b271c84d..3c52fd5ec2 100755 --- a/spec/views/campaigns/edit.js.haml_spec.rb +++ b/spec/views/campaigns/edit.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/campaigns/edit" do +describe "campaigns/edit" do include CampaignsHelper before do diff --git a/spec/views/campaigns/index.haml_spec.rb b/spec/views/campaigns/index.haml_spec.rb index f7963115ea..5e9c4a998f 100644 --- a/spec/views/campaigns/index.haml_spec.rb +++ b/spec/views/campaigns/index.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/campaigns/index" do +describe "campaigns/index" do include CampaignsHelper before do diff --git a/spec/views/campaigns/index.js.haml_spec.rb b/spec/views/campaigns/index.js.haml_spec.rb index a33498fd4f..8a9e8bf38e 100755 --- a/spec/views/campaigns/index.js.haml_spec.rb +++ b/spec/views/campaigns/index.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/campaigns/index" do +describe "campaigns/index" do include CampaignsHelper before do diff --git a/spec/views/campaigns/new.js.haml_spec.rb b/spec/views/campaigns/new.js.haml_spec.rb index 5424cb3df8..244105f50f 100755 --- a/spec/views/campaigns/new.js.haml_spec.rb +++ b/spec/views/campaigns/new.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/campaigns/new" do +describe "campaigns/new" do include CampaignsHelper before do diff --git a/spec/views/campaigns/show.haml_spec.rb b/spec/views/campaigns/show.haml_spec.rb index 223ccc7232..8f5cedfc8d 100644 --- a/spec/views/campaigns/show.haml_spec.rb +++ b/spec/views/campaigns/show.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/campaigns/show" do +describe "campaigns/show" do include CampaignsHelper before do diff --git a/spec/views/campaigns/update.js.haml_spec.rb b/spec/views/campaigns/update.js.haml_spec.rb index cd554eeabc..9d6a7c8a32 100755 --- a/spec/views/campaigns/update.js.haml_spec.rb +++ b/spec/views/campaigns/update.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/campaigns/update" do +describe "campaigns/update" do before do login assign(:campaign, @campaign = build_stubbed(:campaign, user: current_user)) diff --git a/spec/views/comments/edit.js.haml_spec.rb b/spec/views/comments/edit.js.haml_spec.rb index 4bbef33694..b2606d1398 100644 --- a/spec/views/comments/edit.js.haml_spec.rb +++ b/spec/views/comments/edit.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/comments/edit" do +describe "comments/edit" do include CommentsHelper before do diff --git a/spec/views/contacts/_edit.haml_spec.rb b/spec/views/contacts/_edit.haml_spec.rb index d1ef7a7557..149d6b4262 100644 --- a/spec/views/contacts/_edit.haml_spec.rb +++ b/spec/views/contacts/_edit.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/contacts/_edit" do +describe "contacts/_edit" do include ContactsHelper before do diff --git a/spec/views/contacts/_new.haml_spec.rb b/spec/views/contacts/_new.haml_spec.rb index 6ecf506c3c..3720f927f1 100644 --- a/spec/views/contacts/_new.haml_spec.rb +++ b/spec/views/contacts/_new.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/contacts/_new" do +describe "contacts/_new" do include ContactsHelper before do diff --git a/spec/views/contacts/create.js.haml_spec.rb b/spec/views/contacts/create.js.haml_spec.rb index 3b3551ef71..bb7947d652 100644 --- a/spec/views/contacts/create.js.haml_spec.rb +++ b/spec/views/contacts/create.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/contacts/create" do +describe "contacts/create" do include ContactsHelper before do diff --git a/spec/views/contacts/destroy.js.haml_spec.rb b/spec/views/contacts/destroy.js.haml_spec.rb index 869e53c345..740ebc59af 100644 --- a/spec/views/contacts/destroy.js.haml_spec.rb +++ b/spec/views/contacts/destroy.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/contacts/destroy" do +describe "contacts/destroy" do include ContactsHelper before do diff --git a/spec/views/contacts/edit.js.haml_spec.rb b/spec/views/contacts/edit.js.haml_spec.rb index ae92f6bd6e..bb3f64d710 100644 --- a/spec/views/contacts/edit.js.haml_spec.rb +++ b/spec/views/contacts/edit.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/contacts/edit" do +describe "contacts/edit" do include ContactsHelper before do diff --git a/spec/views/contacts/index.haml_spec.rb b/spec/views/contacts/index.haml_spec.rb index 7d40c75cce..b3cded6801 100644 --- a/spec/views/contacts/index.haml_spec.rb +++ b/spec/views/contacts/index.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/contacts/index" do +describe "contacts/index" do include ContactsHelper before do diff --git a/spec/views/contacts/index.js.html_spec.rb b/spec/views/contacts/index.js.html_spec.rb index 924a53827f..4c9bb39091 100644 --- a/spec/views/contacts/index.js.html_spec.rb +++ b/spec/views/contacts/index.js.html_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/contacts/index" do +describe "contacts/index" do include ContactsHelper before do diff --git a/spec/views/contacts/new.js.haml_spec.rb b/spec/views/contacts/new.js.haml_spec.rb index 252ab8fef9..1527c1144c 100644 --- a/spec/views/contacts/new.js.haml_spec.rb +++ b/spec/views/contacts/new.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/contacts/new" do +describe "contacts/new" do include ContactsHelper before do diff --git a/spec/views/contacts/show.haml_spec.rb b/spec/views/contacts/show.haml_spec.rb index 5e2b827d0a..a5244547a8 100644 --- a/spec/views/contacts/show.haml_spec.rb +++ b/spec/views/contacts/show.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/contacts/show" do +describe "contacts/show" do include ContactsHelper before do diff --git a/spec/views/contacts/update.js.haml_spec.rb b/spec/views/contacts/update.js.haml_spec.rb index 9795fb433c..a2286a3395 100644 --- a/spec/views/contacts/update.js.haml_spec.rb +++ b/spec/views/contacts/update.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/contacts/update" do +describe "contacts/update" do include ContactsHelper before do diff --git a/spec/views/home/index.haml_spec.rb b/spec/views/home/index.haml_spec.rb index daa2a288e5..fef01d86dd 100644 --- a/spec/views/home/index.haml_spec.rb +++ b/spec/views/home/index.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/home/index" do +describe "home/index" do include HomeHelper before do diff --git a/spec/views/home/index.js.haml_spec.rb b/spec/views/home/index.js.haml_spec.rb index 832dc18eb8..98d735daf4 100644 --- a/spec/views/home/index.js.haml_spec.rb +++ b/spec/views/home/index.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/home/index" do +describe "home/index" do include HomeHelper before do diff --git a/spec/views/home/options.js.haml_spec.rb b/spec/views/home/options.js.haml_spec.rb index b6945f0c28..db232612de 100644 --- a/spec/views/home/options.js.haml_spec.rb +++ b/spec/views/home/options.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/home/options" do +describe "home/options" do before do login end diff --git a/spec/views/leads/_convert.haml_spec.rb b/spec/views/leads/_convert.haml_spec.rb index 8fedae9546..339bb89c38 100644 --- a/spec/views/leads/_convert.haml_spec.rb +++ b/spec/views/leads/_convert.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/leads/_convert" do +describe "leads/_convert" do include LeadsHelper before do diff --git a/spec/views/leads/_edit.haml_spec.rb b/spec/views/leads/_edit.haml_spec.rb index 236865e4be..37c5a950c7 100644 --- a/spec/views/leads/_edit.haml_spec.rb +++ b/spec/views/leads/_edit.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/leads/_edit" do +describe "leads/_edit" do include LeadsHelper before do diff --git a/spec/views/leads/_new.haml_spec.rb b/spec/views/leads/_new.haml_spec.rb index 792c0d0e7d..bd1d495b4c 100644 --- a/spec/views/leads/_new.haml_spec.rb +++ b/spec/views/leads/_new.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/leads/_new" do +describe "leads/_new" do include LeadsHelper before do diff --git a/spec/views/leads/_sidebar_show.haml_spec.rb b/spec/views/leads/_sidebar_show.haml_spec.rb index 5d81007ee3..1061c97bf7 100644 --- a/spec/views/leads/_sidebar_show.haml_spec.rb +++ b/spec/views/leads/_sidebar_show.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/leads/_sidebar_show" do +describe "leads/_sidebar_show" do include LeadsHelper before do diff --git a/spec/views/leads/convert.js.haml_spec.rb b/spec/views/leads/convert.js.haml_spec.rb index a3ad83a7cb..efa41996d6 100755 --- a/spec/views/leads/convert.js.haml_spec.rb +++ b/spec/views/leads/convert.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/convert" do +describe "leads/convert" do include LeadsHelper before do diff --git a/spec/views/leads/create.js.haml_spec.rb b/spec/views/leads/create.js.haml_spec.rb index 2d3b4ab2ff..c554c1e1c4 100755 --- a/spec/views/leads/create.js.haml_spec.rb +++ b/spec/views/leads/create.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/create" do +describe "leads/create" do before do controller.controller_path = 'leads' login diff --git a/spec/views/leads/destroy.js.haml_spec.rb b/spec/views/leads/destroy.js.haml_spec.rb index c0b44a77c5..003820e851 100755 --- a/spec/views/leads/destroy.js.haml_spec.rb +++ b/spec/views/leads/destroy.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/destroy" do +describe "leads/destroy" do before do login assign(:lead, @lead = build_stubbed(:lead)) diff --git a/spec/views/leads/edit.js.haml_spec.rb b/spec/views/leads/edit.js.haml_spec.rb index 7d01ba70bb..ded616c9c1 100755 --- a/spec/views/leads/edit.js.haml_spec.rb +++ b/spec/views/leads/edit.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/edit" do +describe "leads/edit" do include LeadsHelper before do diff --git a/spec/views/leads/index.haml_spec.rb b/spec/views/leads/index.haml_spec.rb index c1284047b6..399bceda1e 100644 --- a/spec/views/leads/index.haml_spec.rb +++ b/spec/views/leads/index.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/leads/index" do +describe "leads/index" do include LeadsHelper before do diff --git a/spec/views/leads/index.js.haml_spec.rb b/spec/views/leads/index.js.haml_spec.rb index 0ce57aeec0..d36ea2dad5 100755 --- a/spec/views/leads/index.js.haml_spec.rb +++ b/spec/views/leads/index.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/index" do +describe "leads/index" do include LeadsHelper before do diff --git a/spec/views/leads/new.js.haml_spec.rb b/spec/views/leads/new.js.haml_spec.rb index dee8667307..cf639fbaac 100755 --- a/spec/views/leads/new.js.haml_spec.rb +++ b/spec/views/leads/new.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/new" do +describe "leads/new" do include LeadsHelper before do diff --git a/spec/views/leads/promote.js.haml_spec.rb b/spec/views/leads/promote.js.haml_spec.rb index 9e36e4a7f4..175883188c 100755 --- a/spec/views/leads/promote.js.haml_spec.rb +++ b/spec/views/leads/promote.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/promote" do +describe "leads/promote" do before do login assign(:users, [current_user]) diff --git a/spec/views/leads/reject.js.haml_spec.rb b/spec/views/leads/reject.js.haml_spec.rb index 5e73f6ea21..425b07a1d7 100755 --- a/spec/views/leads/reject.js.haml_spec.rb +++ b/spec/views/leads/reject.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/reject" do +describe "leads/reject" do before do login assign(:lead, @lead = build_stubbed(:lead, status: "new")) diff --git a/spec/views/leads/show.haml_spec.rb b/spec/views/leads/show.haml_spec.rb index bf223621ee..464a428c5c 100644 --- a/spec/views/leads/show.haml_spec.rb +++ b/spec/views/leads/show.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/leads/show" do +describe "leads/show" do include LeadsHelper before do diff --git a/spec/views/leads/update.js.haml_spec.rb b/spec/views/leads/update.js.haml_spec.rb index b0b9296ce0..0f6c91e1ff 100755 --- a/spec/views/leads/update.js.haml_spec.rb +++ b/spec/views/leads/update.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/leads/update" do +describe "leads/update" do before do login assign(:lead, @lead = build_stubbed(:lead, user: current_user, assignee: build_stubbed(:user))) diff --git a/spec/views/opportunities/_edit.haml_spec.rb b/spec/views/opportunities/_edit.haml_spec.rb index 3b2ea54b5d..09e962e094 100644 --- a/spec/views/opportunities/_edit.haml_spec.rb +++ b/spec/views/opportunities/_edit.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/opportunities/_edit" do +describe "opportunities/_edit" do include OpportunitiesHelper before do diff --git a/spec/views/opportunities/_new.haml_spec.rb b/spec/views/opportunities/_new.haml_spec.rb index 1d329bb6fc..9d98498ce6 100644 --- a/spec/views/opportunities/_new.haml_spec.rb +++ b/spec/views/opportunities/_new.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/opportunities/_new" do +describe "opportunities/_new" do include OpportunitiesHelper before do diff --git a/spec/views/opportunities/create.js.haml_spec.rb b/spec/views/opportunities/create.js.haml_spec.rb index 562f3d866d..a76a375466 100644 --- a/spec/views/opportunities/create.js.haml_spec.rb +++ b/spec/views/opportunities/create.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/opportunities/create" do +describe "opportunities/create" do before do login assign(:stage, Setting.unroll(:opportunity_stage)) diff --git a/spec/views/opportunities/destroy.js.haml_spec.rb b/spec/views/opportunities/destroy.js.haml_spec.rb index 31f85d528a..3cd54651d5 100644 --- a/spec/views/opportunities/destroy.js.haml_spec.rb +++ b/spec/views/opportunities/destroy.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/opportunities/destroy" do +describe "opportunities/destroy" do before do login assign(:opportunity, @opportunity = build_stubbed(:opportunity)) diff --git a/spec/views/opportunities/edit.js.haml_spec.rb b/spec/views/opportunities/edit.js.haml_spec.rb index 6ade25c911..d29271bf28 100644 --- a/spec/views/opportunities/edit.js.haml_spec.rb +++ b/spec/views/opportunities/edit.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/opportunities/edit" do +describe "opportunities/edit" do include OpportunitiesHelper before do diff --git a/spec/views/opportunities/index.haml_spec.rb b/spec/views/opportunities/index.haml_spec.rb index 96b461c133..467e1d1079 100644 --- a/spec/views/opportunities/index.haml_spec.rb +++ b/spec/views/opportunities/index.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/opportunities/index" do +describe "opportunities/index" do include OpportunitiesHelper before do diff --git a/spec/views/opportunities/index.js.haml_spec.rb b/spec/views/opportunities/index.js.haml_spec.rb index 412ca5d9a8..f33d34c2ba 100644 --- a/spec/views/opportunities/index.js.haml_spec.rb +++ b/spec/views/opportunities/index.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/opportunities/index" do +describe "opportunities/index" do include OpportunitiesHelper before do diff --git a/spec/views/opportunities/new.js.haml_spec.rb b/spec/views/opportunities/new.js.haml_spec.rb index d3b37d3170..8d083b6ce4 100644 --- a/spec/views/opportunities/new.js.haml_spec.rb +++ b/spec/views/opportunities/new.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/opportunities/new" do +describe "opportunities/new" do include OpportunitiesHelper before do diff --git a/spec/views/opportunities/show.haml_spec.rb b/spec/views/opportunities/show.haml_spec.rb index 6b3ea72c8b..aa1157b626 100644 --- a/spec/views/opportunities/show.haml_spec.rb +++ b/spec/views/opportunities/show.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/opportunities/show" do +describe "opportunities/show" do include OpportunitiesHelper before do diff --git a/spec/views/opportunities/update.js.haml_spec.rb b/spec/views/opportunities/update.js.haml_spec.rb index ba5430212f..da69c7330c 100644 --- a/spec/views/opportunities/update.js.haml_spec.rb +++ b/spec/views/opportunities/update.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/opportunities/update" do +describe "opportunities/update" do before do login diff --git a/spec/views/tasks/_edit.haml_spec.rb b/spec/views/tasks/_edit.haml_spec.rb index 49d039ff38..c394aca724 100644 --- a/spec/views/tasks/_edit.haml_spec.rb +++ b/spec/views/tasks/_edit.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/_edit" do +describe "tasks/_edit" do include TasksHelper before do diff --git a/spec/views/tasks/complete.js.haml_spec.rb b/spec/views/tasks/complete.js.haml_spec.rb index b11a989042..434056437c 100644 --- a/spec/views/tasks/complete.js.haml_spec.rb +++ b/spec/views/tasks/complete.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/complete" do +describe "tasks/complete" do include TasksHelper before do diff --git a/spec/views/tasks/create.js.haml_spec.rb b/spec/views/tasks/create.js.haml_spec.rb index 10d5ada09e..55e7c61eff 100644 --- a/spec/views/tasks/create.js.haml_spec.rb +++ b/spec/views/tasks/create.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/create" do +describe "tasks/create" do include TasksHelper before do diff --git a/spec/views/tasks/destroy.js.haml_spec.rb b/spec/views/tasks/destroy.js.haml_spec.rb index 8e132d7944..55bd96cc81 100644 --- a/spec/views/tasks/destroy.js.haml_spec.rb +++ b/spec/views/tasks/destroy.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/destroy" do +describe "tasks/destroy" do include TasksHelper before do diff --git a/spec/views/tasks/edit.js.haml_spec.rb b/spec/views/tasks/edit.js.haml_spec.rb index bc529f5840..bc44dd4dd9 100644 --- a/spec/views/tasks/edit.js.haml_spec.rb +++ b/spec/views/tasks/edit.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/edit" do +describe "tasks/edit" do include TasksHelper before do diff --git a/spec/views/tasks/index.haml_spec.rb b/spec/views/tasks/index.haml_spec.rb index 179fccfad4..fad9363aa2 100644 --- a/spec/views/tasks/index.haml_spec.rb +++ b/spec/views/tasks/index.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/index" do +describe "tasks/index" do include TasksHelper before do diff --git a/spec/views/tasks/new.js.haml_spec.rb b/spec/views/tasks/new.js.haml_spec.rb index e7c8cef54c..cc40a8e9a8 100644 --- a/spec/views/tasks/new.js.haml_spec.rb +++ b/spec/views/tasks/new.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/new" do +describe "tasks/new" do include TasksHelper before do diff --git a/spec/views/tasks/uncomplete.js.haml_spec.rb b/spec/views/tasks/uncomplete.js.haml_spec.rb index a417228f9f..0b6e9bb16c 100644 --- a/spec/views/tasks/uncomplete.js.haml_spec.rb +++ b/spec/views/tasks/uncomplete.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/uncomplete" do +describe "tasks/uncomplete" do include TasksHelper before do diff --git a/spec/views/tasks/update.js.haml_spec.rb b/spec/views/tasks/update.js.haml_spec.rb index 15659eca70..a1ce3b64c1 100644 --- a/spec/views/tasks/update.js.haml_spec.rb +++ b/spec/views/tasks/update.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/tasks/update" do +describe "tasks/update" do include TasksHelper before do diff --git a/spec/views/users/avatar.js.haml_spec.rb b/spec/views/users/avatar.js.haml_spec.rb index b204d494df..54fb149aca 100644 --- a/spec/views/users/avatar.js.haml_spec.rb +++ b/spec/views/users/avatar.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe "/users/avatar" do +describe "users/avatar" do include UsersHelper before do diff --git a/spec/views/users/change_password.js.haml_spec.rb b/spec/views/users/change_password.js.haml_spec.rb index 218ef9312b..db1fa0fece 100644 --- a/spec/views/users/change_password.js.haml_spec.rb +++ b/spec/views/users/change_password.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/users/change_password" do +describe "users/change_password" do include UsersHelper before do diff --git a/spec/views/users/edit.js.haml_spec.rb b/spec/views/users/edit.js.haml_spec.rb index e7db265527..f0c6ab7349 100644 --- a/spec/views/users/edit.js.haml_spec.rb +++ b/spec/views/users/edit.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/users/edit" do +describe "users/edit" do include UsersHelper before do diff --git a/spec/views/users/password.js.haml_spec.rb b/spec/views/users/password.js.haml_spec.rb index 89fb83e572..0125cb5e93 100644 --- a/spec/views/users/password.js.haml_spec.rb +++ b/spec/views/users/password.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/users/password" do +describe "users/password" do include UsersHelper before do diff --git a/spec/views/users/update.js.haml_spec.rb b/spec/views/users/update.js.haml_spec.rb index ac7e7bd65f..cd4b651821 100644 --- a/spec/views/users/update.js.haml_spec.rb +++ b/spec/views/users/update.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/users/update" do +describe "users/update" do include UsersHelper before do diff --git a/spec/views/users/upload_avatar.js.haml_spec.rb b/spec/views/users/upload_avatar.js.haml_spec.rb index 647597ebce..0b2242a5b6 100644 --- a/spec/views/users/upload_avatar.js.haml_spec.rb +++ b/spec/views/users/upload_avatar.js.haml_spec.rb @@ -7,7 +7,7 @@ #------------------------------------------------------------------------------ require 'spec_helper' -describe "/users/upload_avatar" do +describe "users/upload_avatar" do include UsersHelper before do