diff --git a/.rspec b/.rspec index 83e16f804..0f30adeb0 100644 --- a/.rspec +++ b/.rspec @@ -1,2 +1,2 @@ --color ---require spec_helper +--require rails_helper diff --git a/README.md b/README.md index e60b47848..10bd59d5d 100644 --- a/README.md +++ b/README.md @@ -65,22 +65,9 @@ L'application tourne à l'adresse `http://localhost:3000`. En local, un utilisateur de test est créé automatiquement, avec les identifiants `test@exemple.fr`/`this is a very complicated password !`. (voir [db/seeds.rb](https://github.com/betagouv/demarches-simplifiees.fr/blob/dev/db/seeds.rb)) -### Programmation des jobs +### Programmation des tâches récurrentes - AutoArchiveProcedureJob.set(cron: "* * * * *").perform_later - WeeklyOverviewJob.set(cron: "0 7 * * MON").perform_later - DeclarativeProceduresJob.set(cron: "* * * * *").perform_later - UpdateAdministrateurUsageStatisticsJob.set(cron: "0 10 * * *").perform_later - FindDubiousProceduresJob.set(cron: "0 0 * * *").perform_later - Administrateurs::ActivateBeforeExpirationJob.set(cron: "0 8 * * *").perform_later - WarnExpiringDossiersJob.set(cron: "0 0 1 * *").perform_later - InstructeurEmailNotificationJob.set(cron: "0 10 * * MON-FRI").perform_later - PurgeUnattachedBlobsJob.set(cron: "0 0 * * *").perform_later - OperationsSignatureJob.set(cron: "0 6 * * *").perform_later - ExpiredDossiersDeletionJob.set(cron: "0 7 * * *").perform_later - PurgeStaleExportsJob.set(cron: "*/5 * * * *").perform_later - NotifyDraftNotSubmittedJob.set(cron: "0 7 * * *").perform_later - DiscardedDossiersDeletionJob.set(cron: "0 7 * * *").perform_later + rails jobs:schedule ### Voir les emails envoyés en local diff --git a/app/assets/stylesheets/new_design/procedure_champs_editor.scss b/app/assets/stylesheets/new_design/procedure_champs_editor.scss index 0e13037b2..d0f54959b 100644 --- a/app/assets/stylesheets/new_design/procedure_champs_editor.scss +++ b/app/assets/stylesheets/new_design/procedure_champs_editor.scss @@ -123,7 +123,7 @@ .champs-editor { .footer { - margin-bottom: 50px; + height: 50px; } .buttons { diff --git a/app/javascript/shared/utils.js b/app/javascript/shared/utils.js index e74ddd78e..26603d954 100644 --- a/app/javascript/shared/utils.js +++ b/app/javascript/shared/utils.js @@ -62,7 +62,6 @@ export function ajax(options) { } export function getJSON(url, data, method = 'get') { - incrementActiveRequestsCount(); data = method !== 'get' ? JSON.stringify(data) : data; return Promise.resolve( $.ajax({ @@ -72,7 +71,7 @@ export function getJSON(url, data, method = 'get') { contentType: 'application/json', dataType: 'json' }) - ).finally(decrementActiveRequestsCount); + ); } export function scrollTo(container, scrollTo) { @@ -115,15 +114,3 @@ export function timeoutable(promise, timeoutDelay) { }); return Promise.race([promise, timeoutPromise]); } - -const DATA_ACTIVE_REQUESTS_COUNT = 'data-active-requests-count'; - -function incrementActiveRequestsCount() { - const count = document.body.getAttribute(DATA_ACTIVE_REQUESTS_COUNT) || '0'; - document.body.setAttribute(DATA_ACTIVE_REQUESTS_COUNT, parseInt(count) + 1); -} - -function decrementActiveRequestsCount() { - const count = document.body.getAttribute(DATA_ACTIVE_REQUESTS_COUNT) || '0'; - document.body.setAttribute(DATA_ACTIVE_REQUESTS_COUNT, parseInt(count) - 1); -} diff --git a/app/jobs/administrateurs/activate_before_expiration_job.rb b/app/jobs/administrateur_activate_before_expiration_job.rb similarity index 65% rename from app/jobs/administrateurs/activate_before_expiration_job.rb rename to app/jobs/administrateur_activate_before_expiration_job.rb index 9c6058666..4b8f01beb 100644 --- a/app/jobs/administrateurs/activate_before_expiration_job.rb +++ b/app/jobs/administrateur_activate_before_expiration_job.rb @@ -1,5 +1,5 @@ -class Administrateurs::ActivateBeforeExpirationJob < ApplicationJob - queue_as :cron +class AdministrateurActivateBeforeExpirationJob < CronJob + self.cron_expression = "0 8 * * *" def perform(*args) Administrateur diff --git a/app/jobs/auto_archive_procedure_job.rb b/app/jobs/auto_archive_procedure_job.rb index 2d06cfbea..25a63d787 100644 --- a/app/jobs/auto_archive_procedure_job.rb +++ b/app/jobs/auto_archive_procedure_job.rb @@ -1,5 +1,5 @@ -class AutoArchiveProcedureJob < ApplicationJob - queue_as :cron +class AutoArchiveProcedureJob < CronJob + self.cron_expression = "* * * * *" def perform(*args) Procedure.publiees.where("auto_archive_on <= ?", Time.zone.today).each do |procedure| diff --git a/app/jobs/auto_receive_dossiers_for_procedure_job.rb b/app/jobs/auto_receive_dossiers_for_procedure_job.rb deleted file mode 100644 index 0dfd2c386..000000000 --- a/app/jobs/auto_receive_dossiers_for_procedure_job.rb +++ /dev/null @@ -1,22 +0,0 @@ -class AutoReceiveDossiersForProcedureJob < ApplicationJob - queue_as :cron - - def perform(procedure_id, state) - procedure = Procedure.find(procedure_id) - - case state - when Dossier.states.fetch(:en_instruction) - procedure - .dossiers - .state_en_construction - .find_each(&:passer_automatiquement_en_instruction!) - when Dossier.states.fetch(:accepte) - procedure - .dossiers - .state_en_construction - .find_each(&:accepter_automatiquement!) - else - raise "Receiving Procedure##{procedure_id} in invalid state \"#{state}\"" - end - end -end diff --git a/app/jobs/cron_job.rb b/app/jobs/cron_job.rb new file mode 100644 index 000000000..13b735e1d --- /dev/null +++ b/app/jobs/cron_job.rb @@ -0,0 +1,29 @@ +class CronJob < ApplicationJob + queue_as :cron + class_attribute :cron_expression + + class << self + def schedule + remove if cron_expression_changed? + set(cron: cron_expression).perform_later if !scheduled? + end + + def remove + delayed_job.destroy if scheduled? + end + + def scheduled? + delayed_job.present? + end + + def cron_expression_changed? + scheduled? && delayed_job.cron != cron_expression + end + + def delayed_job + Delayed::Job + .where('handler LIKE ?', "%job_class: #{name}%") + .first + end + end +end diff --git a/app/jobs/declarative_procedures_job.rb b/app/jobs/declarative_procedures_job.rb index 7242c2215..6f50d5ffa 100644 --- a/app/jobs/declarative_procedures_job.rb +++ b/app/jobs/declarative_procedures_job.rb @@ -1,5 +1,5 @@ -class DeclarativeProceduresJob < ApplicationJob - queue_as :cron +class DeclarativeProceduresJob < CronJob + self.cron_expression = "* * * * *" def perform(*args) Procedure.declarative.find_each(&:process_dossiers!) diff --git a/app/jobs/discarded_dossiers_deletion_job.rb b/app/jobs/discarded_dossiers_deletion_job.rb index 4fc061ad5..6b4b2d232 100644 --- a/app/jobs/discarded_dossiers_deletion_job.rb +++ b/app/jobs/discarded_dossiers_deletion_job.rb @@ -1,5 +1,5 @@ -class DiscardedDossiersDeletionJob < ApplicationJob - queue_as :cron +class DiscardedDossiersDeletionJob < CronJob + self.cron_expression = "0 7 * * *" def perform(*args) Dossier.discarded_brouillon_expired.destroy_all diff --git a/app/jobs/etablissement_update_job.rb b/app/jobs/etablissement_update_job.rb index 537f28ca6..134d9b26d 100644 --- a/app/jobs/etablissement_update_job.rb +++ b/app/jobs/etablissement_update_job.rb @@ -1,6 +1,4 @@ class EtablissementUpdateJob < ApplicationJob - queue_as :default - def perform(dossier, siret) begin etablissement_attributes = ApiEntrepriseService.get_etablissement_params_for_siret(siret, dossier.procedure_id) diff --git a/app/jobs/expired_dossiers_deletion_job.rb b/app/jobs/expired_dossiers_deletion_job.rb index f269d595a..48d244b03 100644 --- a/app/jobs/expired_dossiers_deletion_job.rb +++ b/app/jobs/expired_dossiers_deletion_job.rb @@ -1,5 +1,5 @@ -class ExpiredDossiersDeletionJob < ApplicationJob - queue_as :cron +class ExpiredDossiersDeletionJob < CronJob + self.cron_expression = "0 7 * * *" def perform(*args) ExpiredDossiersDeletionService.process_expired_dossiers_brouillon diff --git a/app/jobs/find_dubious_procedures_job.rb b/app/jobs/find_dubious_procedures_job.rb index 187f1ad25..044d563ad 100644 --- a/app/jobs/find_dubious_procedures_job.rb +++ b/app/jobs/find_dubious_procedures_job.rb @@ -1,5 +1,5 @@ -class FindDubiousProceduresJob < ApplicationJob - queue_as :cron +class FindDubiousProceduresJob < CronJob + self.cron_expression = "0 0 * * *" FORBIDDEN_KEYWORDS = [ 'NIR', 'NIRPP', 'race', 'religion', diff --git a/app/jobs/instructeur_email_notification_job.rb b/app/jobs/instructeur_email_notification_job.rb index ccab40708..7c442cd6c 100644 --- a/app/jobs/instructeur_email_notification_job.rb +++ b/app/jobs/instructeur_email_notification_job.rb @@ -1,5 +1,5 @@ -class InstructeurEmailNotificationJob < ApplicationJob - queue_as :cron +class InstructeurEmailNotificationJob < CronJob + self.cron_expression = "0 10 * * MON-FRI" def perform(*args) NotificationService.send_instructeur_email_notification diff --git a/app/jobs/notify_draft_not_submitted_job.rb b/app/jobs/notify_draft_not_submitted_job.rb index 82958c538..f4ceebcdd 100644 --- a/app/jobs/notify_draft_not_submitted_job.rb +++ b/app/jobs/notify_draft_not_submitted_job.rb @@ -1,5 +1,5 @@ -class NotifyDraftNotSubmittedJob < ApplicationJob - queue_as :cron +class NotifyDraftNotSubmittedJob < CronJob + self.cron_expression = "0 7 * * *" def perform(*args) Dossier.notify_draft_not_submitted diff --git a/app/jobs/operations_signature_job.rb b/app/jobs/operations_signature_job.rb index 092aec740..ffb98bf9b 100644 --- a/app/jobs/operations_signature_job.rb +++ b/app/jobs/operations_signature_job.rb @@ -1,5 +1,5 @@ -class OperationsSignatureJob < ApplicationJob - queue_as :cron +class OperationsSignatureJob < CronJob + self.cron_expression = "0 6 * * *" def perform(*args) last_midnight = Time.zone.today.beginning_of_day diff --git a/app/jobs/purge_stale_exports_job.rb b/app/jobs/purge_stale_exports_job.rb index 6a40feec6..ff8389c1d 100644 --- a/app/jobs/purge_stale_exports_job.rb +++ b/app/jobs/purge_stale_exports_job.rb @@ -1,5 +1,5 @@ -class PurgeStaleExportsJob < ApplicationJob - queue_as :cron +class PurgeStaleExportsJob < CronJob + self.cron_expression = "*/5 * * * *" def perform Export.stale.destroy_all diff --git a/app/jobs/purge_unattached_blobs_job.rb b/app/jobs/purge_unattached_blobs_job.rb index fb5d5804e..961b4542e 100644 --- a/app/jobs/purge_unattached_blobs_job.rb +++ b/app/jobs/purge_unattached_blobs_job.rb @@ -1,5 +1,5 @@ -class PurgeUnattachedBlobsJob < ApplicationJob - queue_as :cron +class PurgeUnattachedBlobsJob < CronJob + self.cron_expression = "0 0 * * *" def perform(*args) ActiveStorage::Blob.unattached diff --git a/app/jobs/update_administrateur_usage_statistics_job.rb b/app/jobs/update_administrateur_usage_statistics_job.rb index a89fc365f..a0959c59c 100644 --- a/app/jobs/update_administrateur_usage_statistics_job.rb +++ b/app/jobs/update_administrateur_usage_statistics_job.rb @@ -1,5 +1,5 @@ -class UpdateAdministrateurUsageStatisticsJob < ApplicationJob - queue_as :cron +class UpdateAdministrateurUsageStatisticsJob < CronJob + self.cron_expression = "0 10 * * *" def perform AdministrateurUsageStatisticsService.new.update_administrateurs diff --git a/app/jobs/warn_expiring_dossiers_job.rb b/app/jobs/warn_expiring_dossiers_job.rb index b8926662d..eec03825e 100644 --- a/app/jobs/warn_expiring_dossiers_job.rb +++ b/app/jobs/warn_expiring_dossiers_job.rb @@ -1,5 +1,5 @@ -class WarnExpiringDossiersJob < ApplicationJob - queue_as :cron +class WarnExpiringDossiersJob < CronJob + self.cron_expression = "0 0 1 * *" def perform(*args) expiring, expired = Dossier diff --git a/app/jobs/web_hook_job.rb b/app/jobs/web_hook_job.rb index 836ea29d9..5bea19d7d 100644 --- a/app/jobs/web_hook_job.rb +++ b/app/jobs/web_hook_job.rb @@ -1,6 +1,4 @@ class WebHookJob < ApplicationJob - queue_as :default - TIMEOUT = 10 def perform(procedure, dossier) diff --git a/app/jobs/weekly_overview_job.rb b/app/jobs/weekly_overview_job.rb index 86a5f4abf..5af0dbf07 100644 --- a/app/jobs/weekly_overview_job.rb +++ b/app/jobs/weekly_overview_job.rb @@ -1,5 +1,5 @@ -class WeeklyOverviewJob < ApplicationJob - queue_as :cron +class WeeklyOverviewJob < CronJob + self.cron_expression = "0 7 * * MON" def perform(*args) # Feature flipped to avoid mails in staging due to unprocessed dossier diff --git a/app/models/champs/piece_justificative_champ.rb b/app/models/champs/piece_justificative_champ.rb index 5677ae7d5..8fcf58027 100644 --- a/app/models/champs/piece_justificative_champ.rb +++ b/app/models/champs/piece_justificative_champ.rb @@ -1,7 +1,8 @@ class Champs::PieceJustificativeChamp < Champ - PIECE_JUSTIFICATIVE_FILE_MAX_SIZE = 200.megabytes + MAX_SIZE = 200.megabytes - PIECE_JUSTIFICATIVE_FILE_ACCEPTED_FORMATS = [ + ACCEPTED_FORMATS = [ + "text/plain", "application/pdf", "application/msword", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", @@ -16,6 +17,13 @@ class Champs::PieceJustificativeChamp < Champ "image/jpeg" ] + # TODO: once we're running on Rails 6, re-enable this validation. + # See https://github.com/betagouv/demarches-simplifiees.fr/issues/4926 + # + # validates :piece_justificative_file, + # content_type: ACCEPTED_FORMATS, + # size: { less_than: MAX_SIZE } + def main_value_name :piece_justificative_file end @@ -28,28 +36,6 @@ class Champs::PieceJustificativeChamp < Champ mandatory? && !piece_justificative_file.attached? end - def piece_justificative_file_errors - errors = [] - - if piece_justificative_file.attached? && piece_justificative_file.previous_changes.present? - if piece_justificative_file.blob.byte_size > PIECE_JUSTIFICATIVE_FILE_MAX_SIZE - errors << "Le fichier #{piece_justificative_file.filename} est trop lourd, il doit faire au plus #{PIECE_JUSTIFICATIVE_FILE_MAX_SIZE.to_s(:human_size, precision: 2)}" - end - - if !piece_justificative_file.blob.content_type.in?(PIECE_JUSTIFICATIVE_FILE_ACCEPTED_FORMATS) - errors << "Le fichier #{piece_justificative_file.filename} est dans un format que nous n'acceptons pas" - end - - # FIXME: add Clamav check - end - - if errors.present? - piece_justificative_file.purge_later - end - - errors - end - def for_api if piece_justificative_file.attached? && (piece_justificative_file.virus_scanner.safe? || piece_justificative_file.virus_scanner.pending?) piece_justificative_file.service_url diff --git a/app/views/admin/attestation_templates/show.pdf.prawn b/app/views/admin/attestation_templates/show.pdf.prawn index 6ea60f129..399bb68be 100644 --- a/app/views/admin/attestation_templates/show.pdf.prawn +++ b/app/views/admin/attestation_templates/show.pdf.prawn @@ -38,12 +38,12 @@ prawn_document(margin: [top_margin, right_margin, bottom_margin, left_margin], p pdf.bounding_box([0, pdf.cursor], width: body_width, height: body_height) do if logo.present? - logo_file = if logo.is_a?(ActiveStorage::Attached::One) + logo_content = if logo.is_a?(ActiveStorage::Attached::One) logo.download else - logo.read + logo.rewind && logo.read end - pdf.image StringIO.new(logo_file), fit: [max_logo_width , max_logo_height], position: :center + pdf.image StringIO.new(logo_content), fit: [max_logo_width , max_logo_height], position: :center end pdf.fill_color grey @@ -57,12 +57,12 @@ prawn_document(margin: [top_margin, right_margin, bottom_margin, left_margin], p if signature.present? pdf.pad_top(40) do - signature_file = if signature.is_a?(ActiveStorage::Attached::One) + signature_content = if signature.is_a?(ActiveStorage::Attached::One) signature.download else - signature.read + signature.rewind && signature.read end - pdf.image StringIO.new(signature_file), fit: [max_signature_size , max_signature_size], position: :right + pdf.image StringIO.new(signature_content), fit: [max_signature_size , max_signature_size], position: :right end end end diff --git a/config/deploy.rb b/config/deploy.rb index 5e7b2062e..fed78c0d9 100644 --- a/config/deploy.rb +++ b/config/deploy.rb @@ -64,6 +64,16 @@ namespace :after_party do end end +namespace :jobs_schedule do + desc "Run jobs_schedule tasks." + task :run do + command %{ + echo "-----> Running jobs_schedule" + #{echo_cmd %[bundle exec rake jobs:schedule]} + } + end +end + namespace :service do desc "Restart puma" task :restart_puma do @@ -123,4 +133,5 @@ task :post_deploy do command 'cd /home/ds/current' invoke :'after_party:run' + invoke :'jobs_schedule:run' end diff --git a/config/locales/active_storage_validations.fr.yml b/config/locales/active_storage_validations.fr.yml new file mode 100644 index 000000000..1494483b0 --- /dev/null +++ b/config/locales/active_storage_validations.fr.yml @@ -0,0 +1,4 @@ +fr: + errors: + messages: + content_type_invalid: n’est pas d’un type accepté diff --git a/config/locales/models/champs/fr.yml b/config/locales/models/champs/fr.yml index 9d9e6b2f0..7a0730a32 100644 --- a/config/locales/models/champs/fr.yml +++ b/config/locales/models/champs/fr.yml @@ -3,3 +3,4 @@ fr: attributes: champ: value: La valeur du champ + piece_justificative_file: La pièce justificative diff --git a/lib/tasks/jobs.rake b/lib/tasks/jobs.rake new file mode 100644 index 000000000..4f937bc44 --- /dev/null +++ b/lib/tasks/jobs.rake @@ -0,0 +1,8 @@ +namespace :jobs do + desc 'Schedule all cron jobs' + task schedule: :environment do + glob = Rails.root.join('app', 'jobs', '**', '*_job.rb') + Dir.glob(glob).each { |f| require f } + CronJob.subclasses.each(&:schedule) + end +end diff --git a/spec/controllers/admin/assigns_controller_spec.rb b/spec/controllers/admin/assigns_controller_spec.rb index 741937dd8..bc48da393 100644 --- a/spec/controllers/admin/assigns_controller_spec.rb +++ b/spec/controllers/admin/assigns_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Admin::AssignsController, type: :controller do let(:admin) { create(:administrateur) } diff --git a/spec/controllers/admin/attestation_templates_controller_spec.rb b/spec/controllers/admin/attestation_templates_controller_spec.rb index 0cfb06397..7e29ab04e 100644 --- a/spec/controllers/admin/attestation_templates_controller_spec.rb +++ b/spec/controllers/admin/attestation_templates_controller_spec.rb @@ -1,4 +1,5 @@ include ActionDispatch::TestProcess + describe Admin::AttestationTemplatesController, type: :controller do let!(:attestation_template) { create(:attestation_template) } let(:admin) { create(:administrateur) } @@ -17,6 +18,14 @@ describe Admin::AttestationTemplatesController, type: :controller do after { Timecop.return } + shared_examples 'rendering a PDF successfully' do + render_views + it 'renders a PDF' do + expect(subject.status).to eq(200) + expect(subject.content_type).to eq('application/pdf') + end + end + describe 'POST #preview' do let(:upload_params) { { title: 't', body: 'b', footer: 'f' } } @@ -36,31 +45,44 @@ describe Admin::AttestationTemplatesController, type: :controller do context 'if an attestation template does not exist on the procedure' do let(:attestation_template) { nil } - it { expect(subject.status).to eq(200) } - it { expect(assigns(:attestation)).to include(upload_params) } + + context 'with images' do + let(:upload_params) { { title: 't', body: 'b', footer: 'f', logo: interlaced_logo } } + + it { expect(assigns(:attestation)).to include({ title: 't', body: 'b', footer: 'f' }) } + it { expect(assigns(:attestation)[:logo]).to be_present } + it_behaves_like 'rendering a PDF successfully' + end + + context 'without images' do + let(:upload_params) { { title: 't', body: 'b', footer: 'f' } } + + it { expect(assigns(:attestation)).to include(upload_params) } + it_behaves_like 'rendering a PDF successfully' + end end context 'if an attestation template exists on the procedure' do after { procedure.attestation_template.destroy } - context 'with logos' do + context 'with images' do let!(:attestation_template) do create(:attestation_template, logo: logo, signature: signature) end - it { expect(subject.status).to eq(200) } it { expect(assigns(:attestation)).to include(upload_params) } it { expect(assigns(:attestation)[:created_at]).to eq(Time.zone.now) } it { expect(assigns(:attestation)[:logo].download).to eq(logo2.read) } it { expect(assigns(:attestation)[:signature].download).to eq(signature2.read) } + it_behaves_like 'rendering a PDF successfully' end - context 'with empty logo' do - it { expect(subject.status).to eq(200) } + context 'without images' do it { expect(assigns(:attestation)).to include(upload_params) } it { expect(assigns(:attestation)[:created_at]).to eq(Time.zone.now) } it { expect(assigns(:attestation)[:logo]).to eq(nil) } it { expect(assigns(:attestation)[:signature]).to eq(nil) } + it_behaves_like 'rendering a PDF successfully' end end end diff --git a/spec/controllers/admin/instructeurs_controller_spec.rb b/spec/controllers/admin/instructeurs_controller_spec.rb index fd92a4757..1c89a9bbd 100644 --- a/spec/controllers/admin/instructeurs_controller_spec.rb +++ b/spec/controllers/admin/instructeurs_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Admin::InstructeursController, type: :controller do let(:admin) { create(:administrateur) } let(:email_2) { 'plip@octo.com' } diff --git a/spec/controllers/admin/mail_templates_controller_spec.rb b/spec/controllers/admin/mail_templates_controller_spec.rb index a2eec599f..b237eeb1d 100644 --- a/spec/controllers/admin/mail_templates_controller_spec.rb +++ b/spec/controllers/admin/mail_templates_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Admin::MailTemplatesController, type: :controller do let(:procedure) { create :procedure } let(:initiated_mail) { Mails::InitiatedMail.default_for_procedure(procedure) } diff --git a/spec/controllers/admin/procedures_controller_spec.rb b/spec/controllers/admin/procedures_controller_spec.rb index 0ff35f9d8..52f9b248b 100644 --- a/spec/controllers/admin/procedures_controller_spec.rb +++ b/spec/controllers/admin/procedures_controller_spec.rb @@ -1,4 +1,3 @@ -require 'spec_helper' require 'uri' describe Admin::ProceduresController, type: :controller do diff --git a/spec/controllers/administrations/omniauth_callbacks_controller_spec.rb b/spec/controllers/administrations/omniauth_callbacks_controller_spec.rb index f98848006..09e68e8c8 100644 --- a/spec/controllers/administrations/omniauth_callbacks_controller_spec.rb +++ b/spec/controllers/administrations/omniauth_callbacks_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Administrations::OmniauthCallbacksController, type: :controller do before(:each) do @request.env["devise.mapping"] = Devise.mappings[:administration] diff --git a/spec/controllers/api/v1/dossiers_controller_spec.rb b/spec/controllers/api/v1/dossiers_controller_spec.rb index ad9907b93..cfbcc11c5 100644 --- a/spec/controllers/api/v1/dossiers_controller_spec.rb +++ b/spec/controllers/api/v1/dossiers_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe API::V1::DossiersController do let(:admin) { create(:administrateur) } let(:token) { admin.renew_api_token } diff --git a/spec/controllers/api/v2/graphql_controller_spec.rb b/spec/controllers/api/v2/graphql_controller_spec.rb index 57e5e4f7f..79ba46128 100644 --- a/spec/controllers/api/v2/graphql_controller_spec.rb +++ b/spec/controllers/api/v2/graphql_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe API::V2::GraphqlController do let(:admin) { create(:administrateur) } let(:token) { admin.renew_api_token } diff --git a/spec/controllers/api_controller_spec.rb b/spec/controllers/api_controller_spec.rb index 1c1535b16..f83116629 100644 --- a/spec/controllers/api_controller_spec.rb +++ b/spec/controllers/api_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe APIController, type: :controller do describe 'valid_token_for_procedure?' do let(:procedure) { create(:procedure) } diff --git a/spec/controllers/application_controller_spec.rb b/spec/controllers/application_controller_spec.rb index 8289c3482..37b9bf8c0 100644 --- a/spec/controllers/application_controller_spec.rb +++ b/spec/controllers/application_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApplicationController, type: :controller do describe 'before_action: set_raven_context' do it 'is present' do diff --git a/spec/controllers/attachments_controller_spec.rb b/spec/controllers/attachments_controller_spec.rb index c9b732ca5..706912383 100644 --- a/spec/controllers/attachments_controller_spec.rb +++ b/spec/controllers/attachments_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe AttachmentsController, type: :controller do let(:user) { create(:user) } diff --git a/spec/controllers/champs/carte_controller_spec.rb b/spec/controllers/champs/carte_controller_spec.rb index dbba13ebb..e1a952714 100644 --- a/spec/controllers/champs/carte_controller_spec.rb +++ b/spec/controllers/champs/carte_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::CarteController, type: :controller do let(:user) { create(:user) } let(:procedure) { create(:procedure, :published) } diff --git a/spec/controllers/champs/dossier_link_controller_spec.rb b/spec/controllers/champs/dossier_link_controller_spec.rb index f4cda12de..f58392579 100644 --- a/spec/controllers/champs/dossier_link_controller_spec.rb +++ b/spec/controllers/champs/dossier_link_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::DossierLinkController, type: :controller do let(:user) { create(:user) } let(:procedure) { create(:procedure, :published) } diff --git a/spec/controllers/champs/siret_controller_spec.rb b/spec/controllers/champs/siret_controller_spec.rb index cd7163803..cc9929ebb 100644 --- a/spec/controllers/champs/siret_controller_spec.rb +++ b/spec/controllers/champs/siret_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::SiretController, type: :controller do let(:user) { create(:user) } let(:procedure) { create(:procedure, :published) } diff --git a/spec/controllers/concerns/procedure_context_concern_spec.rb b/spec/controllers/concerns/procedure_context_concern_spec.rb index 5911e1686..9a3f81e25 100644 --- a/spec/controllers/concerns/procedure_context_concern_spec.rb +++ b/spec/controllers/concerns/procedure_context_concern_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe ProcedureContextConcern, type: :controller do class TestController < ActionController::Base include ProcedureContextConcern diff --git a/spec/controllers/devise/store_location_extension_spec.rb b/spec/controllers/devise/store_location_extension_spec.rb index f43a041b4..1156fcdd0 100644 --- a/spec/controllers/devise/store_location_extension_spec.rb +++ b/spec/controllers/devise/store_location_extension_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe Devise::StoreLocationExtension, type: :controller do class TestController < ActionController::Base include Devise::Controllers::StoreLocation diff --git a/spec/controllers/instructeurs/avis_controller_spec.rb b/spec/controllers/instructeurs/avis_controller_spec.rb index bdefc0009..52c1f5d5d 100644 --- a/spec/controllers/instructeurs/avis_controller_spec.rb +++ b/spec/controllers/instructeurs/avis_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Instructeurs::AvisController, type: :controller do context 'with a instructeur signed in' do render_views diff --git a/spec/controllers/instructeurs/dossiers_controller_spec.rb b/spec/controllers/instructeurs/dossiers_controller_spec.rb index 80e0afe42..c9a0b13ef 100644 --- a/spec/controllers/instructeurs/dossiers_controller_spec.rb +++ b/spec/controllers/instructeurs/dossiers_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Instructeurs::DossiersController, type: :controller do render_views diff --git a/spec/controllers/instructeurs/instructeur_controller_spec.rb b/spec/controllers/instructeurs/instructeur_controller_spec.rb index 3c8ae4dff..3825a6801 100644 --- a/spec/controllers/instructeurs/instructeur_controller_spec.rb +++ b/spec/controllers/instructeurs/instructeur_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Instructeurs::InstructeurController, type: :controller do describe 'before actions: authenticate_instructeur!' do it 'is present' do diff --git a/spec/controllers/instructeurs/procedures_controller_spec.rb b/spec/controllers/instructeurs/procedures_controller_spec.rb index 638d4313b..a3965bca6 100644 --- a/spec/controllers/instructeurs/procedures_controller_spec.rb +++ b/spec/controllers/instructeurs/procedures_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Instructeurs::ProceduresController, type: :controller do describe "before_action: ensure_ownership!" do it "is present" do diff --git a/spec/controllers/instructeurs/recherche_controller_spec.rb b/spec/controllers/instructeurs/recherche_controller_spec.rb index 415939a1d..8698c6102 100644 --- a/spec/controllers/instructeurs/recherche_controller_spec.rb +++ b/spec/controllers/instructeurs/recherche_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Instructeurs::RechercheController, type: :controller do let(:dossier) { create(:dossier, :en_construction) } let(:dossier2) { create(:dossier, :en_construction, procedure: dossier.procedure) } diff --git a/spec/controllers/invites_controller_spec.rb b/spec/controllers/invites_controller_spec.rb index 3a78d9fba..c26030a8b 100644 --- a/spec/controllers/invites_controller_spec.rb +++ b/spec/controllers/invites_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe InvitesController, type: :controller do let(:dossier) { create(:dossier, :en_construction) } let(:email) { 'plop@octo.com' } diff --git a/spec/controllers/ping_controller_spec.rb b/spec/controllers/ping_controller_spec.rb index 1c723512c..0649048f7 100644 --- a/spec/controllers/ping_controller_spec.rb +++ b/spec/controllers/ping_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe PingController, type: :controller do describe 'GET #index' do subject { get :index } diff --git a/spec/controllers/root_controller_spec.rb b/spec/controllers/root_controller_spec.rb index 0afe43037..0e9b25956 100644 --- a/spec/controllers/root_controller_spec.rb +++ b/spec/controllers/root_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe RootController, type: :controller do subject { get :index } diff --git a/spec/controllers/stats_controller_spec.rb b/spec/controllers/stats_controller_spec.rb index b70d75fab..d4547e81c 100644 --- a/spec/controllers/stats_controller_spec.rb +++ b/spec/controllers/stats_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe StatsController, type: :controller do describe "#last_four_months_hash" do context "while a regular user is logged in" do diff --git a/spec/controllers/support_controller_spec.rb b/spec/controllers/support_controller_spec.rb index 4ae584139..72ebfcff0 100644 --- a/spec/controllers/support_controller_spec.rb +++ b/spec/controllers/support_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe SupportController, type: :controller do render_views diff --git a/spec/controllers/users/commencer_controller_spec.rb b/spec/controllers/users/commencer_controller_spec.rb index 539cfaa7c..bf80703e8 100644 --- a/spec/controllers/users/commencer_controller_spec.rb +++ b/spec/controllers/users/commencer_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Users::CommencerController, type: :controller do let(:user) { create(:user) } let(:published_procedure) { create(:procedure, :published) } diff --git a/spec/controllers/users/confirmations_controller_spec.rb b/spec/controllers/users/confirmations_controller_spec.rb index 1944d1a6a..758cde53f 100644 --- a/spec/controllers/users/confirmations_controller_spec.rb +++ b/spec/controllers/users/confirmations_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Users::ConfirmationsController, type: :controller do let!(:user) { create(:user, :unconfirmed) } let(:confirmation_token) { user.confirmation_token } diff --git a/spec/controllers/users/dossiers_controller_spec.rb b/spec/controllers/users/dossiers_controller_spec.rb index b0e34bc9b..9802b7c36 100644 --- a/spec/controllers/users/dossiers_controller_spec.rb +++ b/spec/controllers/users/dossiers_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Users::DossiersController, type: :controller do let(:user) { create(:user) } diff --git a/spec/controllers/users/passwords_controller_spec.rb b/spec/controllers/users/passwords_controller_spec.rb index 216f1ca45..f52ebc65f 100644 --- a/spec/controllers/users/passwords_controller_spec.rb +++ b/spec/controllers/users/passwords_controller_spec.rb @@ -1,5 +1,3 @@ -require "spec_helper" - describe Users::PasswordsController, type: :controller do before do @request.env["devise.mapping"] = Devise.mappings[:user] diff --git a/spec/controllers/users/profil_controller_spec.rb b/spec/controllers/users/profil_controller_spec.rb index 82fe1706e..2d79fca85 100644 --- a/spec/controllers/users/profil_controller_spec.rb +++ b/spec/controllers/users/profil_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Users::ProfilController, type: :controller do include ActiveJob::TestHelper diff --git a/spec/controllers/users/user_controller_spec.rb b/spec/controllers/users/user_controller_spec.rb index f5601760e..d8a224919 100644 --- a/spec/controllers/users/user_controller_spec.rb +++ b/spec/controllers/users/user_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Users::UserController, type: :controller do describe 'before actions: authenticate_instructeur!' do it 'is present' do diff --git a/spec/controllers/webhook_controller_spec.rb b/spec/controllers/webhook_controller_spec.rb index 81e07e8c6..26badc63c 100644 --- a/spec/controllers/webhook_controller_spec.rb +++ b/spec/controllers/webhook_controller_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe WebhookController, type: :controller do describe '#helpscout' do before { allow(controller).to receive(:verify_signature!).and_return(true) } diff --git a/spec/features/admin/admin_creation_spec.rb b/spec/features/admin/admin_creation_spec.rb index a5ce312dc..88e3de6b4 100644 --- a/spec/features/admin/admin_creation_spec.rb +++ b/spec/features/admin/admin_creation_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'As an administrateur', js: true do let(:administration) { create(:administration) } let(:admin_email) { 'new_admin@gouv.fr' } diff --git a/spec/features/admin/procedure_cloning_spec.rb b/spec/features/admin/procedure_cloning_spec.rb index 2377e7980..1550f41be 100644 --- a/spec/features/admin/procedure_cloning_spec.rb +++ b/spec/features/admin/procedure_cloning_spec.rb @@ -1,4 +1,3 @@ -require 'spec_helper' require 'features/admin/procedure_spec_helper' feature 'As an administrateur I wanna clone a procedure', js: true do diff --git a/spec/features/admin/procedure_creation_spec.rb b/spec/features/admin/procedure_creation_spec.rb index de7b75a29..2f33cf8ab 100644 --- a/spec/features/admin/procedure_creation_spec.rb +++ b/spec/features/admin/procedure_creation_spec.rb @@ -1,4 +1,3 @@ -require 'spec_helper' require 'features/admin/procedure_spec_helper' feature 'As an administrateur I wanna create a new procedure', js: true do diff --git a/spec/features/admin/procedure_locked_spec.rb b/spec/features/admin/procedure_locked_spec.rb index eeb76dd44..a358e8fc1 100644 --- a/spec/features/admin/procedure_locked_spec.rb +++ b/spec/features/admin/procedure_locked_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'procedure locked' do let(:administrateur) { create(:administrateur) } diff --git a/spec/features/admin/procedure_update_spec.rb b/spec/features/admin/procedure_update_spec.rb index 7fc165ab3..9a8c98f79 100644 --- a/spec/features/admin/procedure_update_spec.rb +++ b/spec/features/admin/procedure_update_spec.rb @@ -1,4 +1,3 @@ -require 'spec_helper' require 'features/admin/procedure_spec_helper' feature 'Administrateurs can edit procedures', js: true do diff --git a/spec/features/france_connect/france_connect_particulier_spec.rb b/spec/features/france_connect/france_connect_particulier_spec.rb index ac26aa26a..123a10d7d 100644 --- a/spec/features/france_connect/france_connect_particulier_spec.rb +++ b/spec/features/france_connect/france_connect_particulier_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'France Connect Particulier Connexion' do let(:code) { 'plop' } let(:given_name) { 'titi' } diff --git a/spec/features/help_spec.rb b/spec/features/help_spec.rb index 0f01cbafb..4aa7de431 100644 --- a/spec/features/help_spec.rb +++ b/spec/features/help_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Getting help:' do scenario 'a Help button is visible on public pages' do visit '/' diff --git a/spec/features/instructeurs/expert_spec.rb b/spec/features/instructeurs/expert_spec.rb index ea81ab324..aa3ebf0b8 100644 --- a/spec/features/instructeurs/expert_spec.rb +++ b/spec/features/instructeurs/expert_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Inviting an expert:' do include ActiveJob::TestHelper include ActionView::Helpers diff --git a/spec/features/instructeurs/instructeur_creation_spec.rb b/spec/features/instructeurs/instructeur_creation_spec.rb index 189144cb6..59ece170c 100644 --- a/spec/features/instructeurs/instructeur_creation_spec.rb +++ b/spec/features/instructeurs/instructeur_creation_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'As an instructeur', js: true do let(:administrateur) { create(:administrateur, :with_procedure) } let(:procedure) { administrateur.procedures.first } diff --git a/spec/features/instructeurs/instruction_spec.rb b/spec/features/instructeurs/instruction_spec.rb index 884b73631..017942f90 100644 --- a/spec/features/instructeurs/instruction_spec.rb +++ b/spec/features/instructeurs/instruction_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Instructing a dossier:' do include ActiveJob::TestHelper diff --git a/spec/features/instructeurs/procedure_filters_spec.rb b/spec/features/instructeurs/procedure_filters_spec.rb index 144305ff7..faaa5f9b4 100644 --- a/spec/features/instructeurs/procedure_filters_spec.rb +++ b/spec/features/instructeurs/procedure_filters_spec.rb @@ -1,5 +1,3 @@ -require "spec_helper" - feature "procedure filters" do let(:instructeur) { create(:instructeur) } let(:procedure) { create(:procedure, :published, :with_type_de_champ, instructeurs: [instructeur]) } diff --git a/spec/features/new_administrateur/types_de_champ_spec.rb b/spec/features/new_administrateur/types_de_champ_spec.rb index ace602aa7..625fb9b1d 100644 --- a/spec/features/new_administrateur/types_de_champ_spec.rb +++ b/spec/features/new_administrateur/types_de_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'As an administrateur I can edit types de champ', js: true do let(:administrateur) { procedure.administrateurs.first } let(:procedure) { create(:procedure) } diff --git a/spec/features/outdated_browser_spec.rb b/spec/features/outdated_browser_spec.rb index e6cb28efb..8ca379658 100644 --- a/spec/features/outdated_browser_spec.rb +++ b/spec/features/outdated_browser_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Outdated browsers support:' do context 'when the user browser is outdated' do before(:each) do diff --git a/spec/features/routing/full_scenario_spec.rb b/spec/features/routing/full_scenario_spec.rb index 0401a8ade..612f38cd4 100644 --- a/spec/features/routing/full_scenario_spec.rb +++ b/spec/features/routing/full_scenario_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'The routing', js: true do let(:password) { 'a very complicated password' } let(:procedure) { create(:procedure, :with_type_de_champ, :with_service, :for_individual) } diff --git a/spec/features/sessions/sign_in_spec.rb b/spec/features/sessions/sign_in_spec.rb index 25ddf3c55..acbecc6dc 100644 --- a/spec/features/sessions/sign_in_spec.rb +++ b/spec/features/sessions/sign_in_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Signin in:' do let!(:user) { create(:user, password: password) } let(:password) { 'démarches-simplifiées-pwd' } diff --git a/spec/features/users/brouillon_spec.rb b/spec/features/users/brouillon_spec.rb index 9de07012e..2b45260b4 100644 --- a/spec/features/users/brouillon_spec.rb +++ b/spec/features/users/brouillon_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - feature 'The user' do let(:password) { 'démarches-simplifiées-pwd' } let!(:user) { create(:user, password: password) } diff --git a/spec/features/users/change_email_spec.rb b/spec/features/users/change_email_spec.rb index 00933a698..016f3ee90 100644 --- a/spec/features/users/change_email_spec.rb +++ b/spec/features/users/change_email_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Changing an email' do let(:old_email) { 'old@email.com' } let(:user) { create(:user, email: old_email) } diff --git a/spec/features/users/dossier_creation_spec.rb b/spec/features/users/dossier_creation_spec.rb index b15f6ece0..6a1a357a8 100644 --- a/spec/features/users/dossier_creation_spec.rb +++ b/spec/features/users/dossier_creation_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Creating a new dossier:' do let(:user) { create(:user) } let(:siret) { '40307130100044' } diff --git a/spec/features/users/invite_spec.rb b/spec/features/users/invite_spec.rb index e1d9cebd0..f80c3ab07 100644 --- a/spec/features/users/invite_spec.rb +++ b/spec/features/users/invite_spec.rb @@ -1,4 +1,3 @@ -require 'spec_helper' require 'features/users/dossier_shared_examples.rb' feature 'Invitations' do diff --git a/spec/features/users/linked_dropdown_spec.rb b/spec/features/users/linked_dropdown_spec.rb index 1b088a0d0..97c7e46ec 100644 --- a/spec/features/users/linked_dropdown_spec.rb +++ b/spec/features/users/linked_dropdown_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'linked dropdown lists' do let(:password) { 'démarches-simplifiées-pwd' } let!(:user) { create(:user, password: password) } diff --git a/spec/features/users/list_dossiers_spec.rb b/spec/features/users/list_dossiers_spec.rb index ee0cf27e9..fa514bd06 100644 --- a/spec/features/users/list_dossiers_spec.rb +++ b/spec/features/users/list_dossiers_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'user access to the list of their dossiers' do let(:user) { create(:user) } let!(:dossier_brouillon) { create(:dossier, user: user) } diff --git a/spec/features/users/managing_password_spec.rb b/spec/features/users/managing_password_spec.rb index 3d0393f1d..52aa4c109 100644 --- a/spec/features/users/managing_password_spec.rb +++ b/spec/features/users/managing_password_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Managing password:' do context 'for simple users' do let(:user) { create(:user) } diff --git a/spec/features/users/sign_out_spec.rb b/spec/features/users/sign_out_spec.rb index b77edb604..85516afcb 100644 --- a/spec/features/users/sign_out_spec.rb +++ b/spec/features/users/sign_out_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Sign out' do context 'when a user is logged in' do let(:user) { create(:administrateur).user } diff --git a/spec/features/users/sign_up_spec.rb b/spec/features/users/sign_up_spec.rb index 4fb8fd0a7..a9a411616 100644 --- a/spec/features/users/sign_up_spec.rb +++ b/spec/features/users/sign_up_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - feature 'Signing up:' do let(:user_email) { generate :user_email } let(:user_password) { 'démarches-simplifiées-pwd' } diff --git a/spec/helpers/commentaire_helper_spec.rb b/spec/helpers/commentaire_helper_spec.rb index c295535e7..e54b1a860 100644 --- a/spec/helpers/commentaire_helper_spec.rb +++ b/spec/helpers/commentaire_helper_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe CommentaireHelper, type: :helper do let(:commentaire) { create(:commentaire, email: "michel@pref.fr") } diff --git a/spec/helpers/conservation_de_donnees_helper_spec.rb b/spec/helpers/conservation_de_donnees_helper_spec.rb index 8edacefe9..e0eb3c181 100644 --- a/spec/helpers/conservation_de_donnees_helper_spec.rb +++ b/spec/helpers/conservation_de_donnees_helper_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe ConservationDeDonneesHelper, type: :helper do let(:procedure) { build(:procedure, duree_conservation_dossiers_dans_ds: dans_ds, duree_conservation_dossiers_hors_ds: hors_ds) } diff --git a/spec/helpers/dossier_helper_spec.rb b/spec/helpers/dossier_helper_spec.rb index aea4f92de..0bf33c397 100644 --- a/spec/helpers/dossier_helper_spec.rb +++ b/spec/helpers/dossier_helper_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe DossierHelper, type: :helper do describe ".highlight_if_unseen_class" do let(:seen_at) { Time.zone.now } diff --git a/spec/jobs/administrateurs/activate_before_expiration_job_spec.rb b/spec/jobs/administrateur_activate_before_expiration_job_spec.rb similarity index 92% rename from spec/jobs/administrateurs/activate_before_expiration_job_spec.rb rename to spec/jobs/administrateur_activate_before_expiration_job_spec.rb index 2b833d561..504f8cef4 100644 --- a/spec/jobs/administrateurs/activate_before_expiration_job_spec.rb +++ b/spec/jobs/administrateur_activate_before_expiration_job_spec.rb @@ -1,12 +1,10 @@ -require 'rails_helper' - -RSpec.describe Administrateurs::ActivateBeforeExpirationJob, type: :job do +RSpec.describe AdministrateurActivateBeforeExpirationJob, type: :job do describe 'perform' do let(:administrateur) { create(:administrateur) } let(:user) { administrateur.user } let(:mailer_double) { double('mailer', deliver_later: true) } - subject { Administrateurs::ActivateBeforeExpirationJob.perform_now } + subject { AdministrateurActivateBeforeExpirationJob.perform_now } before do Timecop.freeze(Time.zone.local(2018, 03, 20)) diff --git a/spec/jobs/application_job_spec.rb b/spec/jobs/application_job_spec.rb index 053156f92..cb1b6ceac 100644 --- a/spec/jobs/application_job_spec.rb +++ b/spec/jobs/application_job_spec.rb @@ -1,4 +1,3 @@ -require 'rails_helper' include ActiveJob::TestHelper RSpec.describe ApplicationJob, type: :job do diff --git a/spec/jobs/auto_archive_procedure_job_spec.rb b/spec/jobs/auto_archive_procedure_job_spec.rb index 52f97ed32..3f1600b6c 100644 --- a/spec/jobs/auto_archive_procedure_job_spec.rb +++ b/spec/jobs/auto_archive_procedure_job_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe AutoArchiveProcedureJob, type: :job do let!(:procedure) { create(:procedure, :published, :with_instructeur, auto_archive_on: nil) } let!(:procedure_hier) { create(:procedure, :published, :with_instructeur, auto_archive_on: 1.day.ago.to_date) } diff --git a/spec/jobs/auto_receive_dossiers_for_procedure_job_spec.rb b/spec/jobs/auto_receive_dossiers_for_procedure_job_spec.rb deleted file mode 100644 index 9e4c173b6..000000000 --- a/spec/jobs/auto_receive_dossiers_for_procedure_job_spec.rb +++ /dev/null @@ -1,81 +0,0 @@ -require 'rails_helper' - -RSpec.describe AutoReceiveDossiersForProcedureJob, type: :job do - describe "perform" do - let(:date) { Time.utc(2017, 9, 1, 10, 5, 0) } - let(:instruction_date) { date + 120 } - - let(:procedure) { create(:procedure, :published, :with_instructeur) } - let(:nouveau_dossier1) { create(:dossier, :en_construction, procedure: procedure) } - let(:nouveau_dossier2) { create(:dossier, :en_construction, procedure: procedure) } - let(:dossier_recu) { create(:dossier, :en_instruction, procedure: procedure) } - let(:dossier_brouillon) { create(:dossier, procedure: procedure) } - - before do - Timecop.freeze(date) - dossiers = [ - nouveau_dossier1, - nouveau_dossier2, - dossier_recu, - dossier_brouillon - ] - - create(:attestation_template, procedure: procedure) - AutoReceiveDossiersForProcedureJob.new.perform(procedure.id, state) - - dossiers.each(&:reload) - end - - after { Timecop.return } - - context "with some dossiers" do - context "en_construction" do - let(:state) { Dossier.states.fetch(:en_instruction) } - let(:last_operation) { nouveau_dossier1.dossier_operation_logs.last } - - it { - expect(nouveau_dossier1.en_instruction?).to be true - expect(nouveau_dossier1.en_instruction_at).to eq(date) - expect(last_operation.operation).to eq('passer_en_instruction') - expect(last_operation.automatic_operation?).to be_truthy - - expect(nouveau_dossier2.en_instruction?).to be true - expect(nouveau_dossier2.en_instruction_at).to eq(date) - - expect(dossier_recu.en_instruction?).to be true - expect(dossier_recu.en_instruction_at).to eq(instruction_date) - - expect(dossier_brouillon.brouillon?).to be true - expect(dossier_brouillon.en_instruction_at).to eq(nil) - } - end - - context "accepte" do - let(:state) { Dossier.states.fetch(:accepte) } - let(:last_operation) { nouveau_dossier1.dossier_operation_logs.last } - - it { - expect(nouveau_dossier1.accepte?).to be true - expect(nouveau_dossier1.en_instruction_at).to eq(date) - expect(nouveau_dossier1.processed_at).to eq(date) - expect(nouveau_dossier1.attestation).to be_present - expect(last_operation.operation).to eq('accepter') - expect(last_operation.automatic_operation?).to be_truthy - - expect(nouveau_dossier2.accepte?).to be true - expect(nouveau_dossier2.en_instruction_at).to eq(date) - expect(nouveau_dossier2.processed_at).to eq(date) - expect(nouveau_dossier2.attestation).to be_present - - expect(dossier_recu.en_instruction?).to be true - expect(dossier_recu.en_instruction_at).to eq(instruction_date) - expect(dossier_recu.processed_at).to eq(nil) - - expect(dossier_brouillon.brouillon?).to be true - expect(dossier_brouillon.en_instruction_at).to eq(nil) - expect(dossier_brouillon.processed_at).to eq(nil) - } - end - end - end -end diff --git a/spec/jobs/declarative_procedures_job_spec.rb b/spec/jobs/declarative_procedures_job_spec.rb index 98a0de5d5..4a4238174 100644 --- a/spec/jobs/declarative_procedures_job_spec.rb +++ b/spec/jobs/declarative_procedures_job_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe DeclarativeProceduresJob, type: :job do describe "perform" do let(:date) { Time.utc(2017, 9, 1, 10, 5, 0) } diff --git a/spec/jobs/find_dubious_procedures_job_spec.rb b/spec/jobs/find_dubious_procedures_job_spec.rb index 06d1123b9..3bd6fd50f 100644 --- a/spec/jobs/find_dubious_procedures_job_spec.rb +++ b/spec/jobs/find_dubious_procedures_job_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe FindDubiousProceduresJob, type: :job do describe 'perform' do let(:mailer_double) { double('mailer', deliver_later: true) } diff --git a/spec/jobs/weekly_overview_job_spec.rb b/spec/jobs/weekly_overview_job_spec.rb index 3e558c4c7..3aa7a44e2 100644 --- a/spec/jobs/weekly_overview_job_spec.rb +++ b/spec/jobs/weekly_overview_job_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe WeeklyOverviewJob, type: :job do describe 'perform' do let!(:instructeur) { create(:instructeur) } diff --git a/spec/lib/api_carto/api_spec.rb b/spec/lib/api_carto/api_spec.rb index bb03c40e5..c0c8dd73b 100644 --- a/spec/lib/api_carto/api_spec.rb +++ b/spec/lib/api_carto/api_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiCarto::API do describe '.search_qp' do subject { described_class.search_qp(geojson) } diff --git a/spec/lib/api_carto/cadastre_adapter_spec.rb b/spec/lib/api_carto/cadastre_adapter_spec.rb index 63d7f83c9..7d2d5860d 100644 --- a/spec/lib/api_carto/cadastre_adapter_spec.rb +++ b/spec/lib/api_carto/cadastre_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiCarto::CadastreAdapter do subject { described_class.new(coordinates).results } diff --git a/spec/lib/api_carto/quartiers_prioritaires_adapter_spec.rb b/spec/lib/api_carto/quartiers_prioritaires_adapter_spec.rb index 70593327d..4f1988bae 100644 --- a/spec/lib/api_carto/quartiers_prioritaires_adapter_spec.rb +++ b/spec/lib/api_carto/quartiers_prioritaires_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiCarto::QuartiersPrioritairesAdapter do subject { described_class.new(coordinates).results } diff --git a/spec/lib/api_entreprise/api_spec.rb b/spec/lib/api_entreprise/api_spec.rb index d247e0f37..403cd460c 100644 --- a/spec/lib/api_entreprise/api_spec.rb +++ b/spec/lib/api_entreprise/api_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiEntreprise::API do let(:procedure_id) { 12 } diff --git a/spec/lib/api_entreprise/entreprise_adapter_spec.rb b/spec/lib/api_entreprise/entreprise_adapter_spec.rb index 56c78d8aa..b3f72e26c 100644 --- a/spec/lib/api_entreprise/entreprise_adapter_spec.rb +++ b/spec/lib/api_entreprise/entreprise_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiEntreprise::EntrepriseAdapter do let(:siren) { '418166096' } let(:procedure_id) { 22 } diff --git a/spec/lib/api_entreprise/etablissement_adapter_spec.rb b/spec/lib/api_entreprise/etablissement_adapter_spec.rb index ba1876a5e..2cd381955 100644 --- a/spec/lib/api_entreprise/etablissement_adapter_spec.rb +++ b/spec/lib/api_entreprise/etablissement_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiEntreprise::EtablissementAdapter do let(:procedure_id) { 33 } diff --git a/spec/lib/api_entreprise/exercices_adapter_spec.rb b/spec/lib/api_entreprise/exercices_adapter_spec.rb index bf0c3e131..d22cf3aab 100644 --- a/spec/lib/api_entreprise/exercices_adapter_spec.rb +++ b/spec/lib/api_entreprise/exercices_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiEntreprise::ExercicesAdapter do let(:siret) { '41816609600051' } let(:procedure_id) { 11 } diff --git a/spec/lib/api_entreprise/rna_adapter_spec.rb b/spec/lib/api_entreprise/rna_adapter_spec.rb index 43d964c1e..3ed08d34b 100644 --- a/spec/lib/api_entreprise/rna_adapter_spec.rb +++ b/spec/lib/api_entreprise/rna_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiEntreprise::RNAAdapter do let(:siret) { '50480511000013' } let(:procedure_id) { 22 } diff --git a/spec/lib/asn1/timestamp_spec.rb b/spec/lib/asn1/timestamp_spec.rb index 3ae0d6272..4d7f03218 100644 --- a/spec/lib/asn1/timestamp_spec.rb +++ b/spec/lib/asn1/timestamp_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ASN1::Timestamp do let(:asn1timestamp) { File.read('spec/fixtures/files/bill_signature/signature.der') } diff --git a/spec/lib/biz_dev_spec.rb b/spec/lib/biz_dev_spec.rb index 475e93332..0d22c87a2 100644 --- a/spec/lib/biz_dev_spec.rb +++ b/spec/lib/biz_dev_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe BizDev, lib: true do let(:first_biz_dev_id) { BizDev::PIPEDRIVE_ID } let(:non_biz_dev_id) { first_biz_dev_id - 1 } diff --git a/spec/lib/helpscout/form_adapter_spec.rb b/spec/lib/helpscout/form_adapter_spec.rb index 8bccafcfc..275d77418 100644 --- a/spec/lib/helpscout/form_adapter_spec.rb +++ b/spec/lib/helpscout/form_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Helpscout::FormAdapter do describe '#send_form' do let(:api) { spy(double(:api)) } diff --git a/spec/lib/helpscout/user_conversations_adapter_spec.rb b/spec/lib/helpscout/user_conversations_adapter_spec.rb index 980fd7d21..84e9f676d 100644 --- a/spec/lib/helpscout/user_conversations_adapter_spec.rb +++ b/spec/lib/helpscout/user_conversations_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Helpscout::UserConversationsAdapter do let(:from) { Date.new(2017, 11) } let(:to) { Date.new(2017, 12) } diff --git a/spec/lib/pipedrive/deal_adapter_spec.rb b/spec/lib/pipedrive/deal_adapter_spec.rb index bce1ad0e5..5d7583673 100644 --- a/spec/lib/pipedrive/deal_adapter_spec.rb +++ b/spec/lib/pipedrive/deal_adapter_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Pipedrive::DealAdapter do let(:url) { PIPEDRIVE_API_URL } let(:status) { 200 } diff --git a/spec/lib/tasks/graphql_spec.rb b/spec/lib/tasks/graphql_spec.rb index 3543a6de5..04bf2ebe8 100644 --- a/spec/lib/tasks/graphql_spec.rb +++ b/spec/lib/tasks/graphql_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'graphql' do let(:current_defn) { Api::V2::Schema.to_definition } let(:printout_defn) { File.read(Rails.root.join('app', 'graphql', 'schema.graphql')) } diff --git a/spec/lib/tasks/task_helper_spec.rb b/spec/lib/tasks/task_helper_spec.rb index 4d02d159c..e0d512dad 100644 --- a/spec/lib/tasks/task_helper_spec.rb +++ b/spec/lib/tasks/task_helper_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ProgressReport, lib: true do context 'when the count pass above 100%' do let(:total) { 2 } diff --git a/spec/lib/typhoeus/cache/successful_requests_rails_cache.rb b/spec/lib/typhoeus/cache/successful_requests_rails_cache.rb index 24c6bb9a1..8940e9002 100644 --- a/spec/lib/typhoeus/cache/successful_requests_rails_cache.rb +++ b/spec/lib/typhoeus/cache/successful_requests_rails_cache.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Typhoeus::Cache::SuccessfulRequestsRailsCache, lib: true do let(:cache) { described_class.new } diff --git a/spec/lib/universign/api_spec.rb b/spec/lib/universign/api_spec.rb index 124076ba5..0d026642c 100644 --- a/spec/lib/universign/api_spec.rb +++ b/spec/lib/universign/api_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Universign::API do describe '.request_timestamp', vcr: { cassette_name: 'universign' } do subject { described_class.timestamp(digest) } diff --git a/spec/mailers/avis_mailer_spec.rb b/spec/mailers/avis_mailer_spec.rb index 06210d773..ff9f5bd7d 100644 --- a/spec/mailers/avis_mailer_spec.rb +++ b/spec/mailers/avis_mailer_spec.rb @@ -1,5 +1,3 @@ -require "rails_helper" - RSpec.describe AvisMailer, type: :mailer do describe '.avis_invitation' do let(:avis) { create(:avis) } diff --git a/spec/mailers/dossier_mailer_spec.rb b/spec/mailers/dossier_mailer_spec.rb index afb42fd98..a7578880b 100644 --- a/spec/mailers/dossier_mailer_spec.rb +++ b/spec/mailers/dossier_mailer_spec.rb @@ -1,5 +1,3 @@ -require "rails_helper" - RSpec.describe DossierMailer, type: :mailer do let(:to_email) { 'instructeur@exemple.gouv.fr' } diff --git a/spec/mailers/notification_mailer_spec.rb b/spec/mailers/notification_mailer_spec.rb index 4301b27b0..667fc4eaf 100644 --- a/spec/mailers/notification_mailer_spec.rb +++ b/spec/mailers/notification_mailer_spec.rb @@ -1,5 +1,3 @@ -require "spec_helper" - RSpec.describe NotificationMailer, type: :mailer do let(:user) { create(:user) } let(:procedure) { create(:simple_procedure) } diff --git a/spec/mailers/user_mailer_spec.rb b/spec/mailers/user_mailer_spec.rb index 6f14cfbfb..651dcc4e8 100644 --- a/spec/mailers/user_mailer_spec.rb +++ b/spec/mailers/user_mailer_spec.rb @@ -1,5 +1,3 @@ -require "rails_helper" - RSpec.describe UserMailer, type: :mailer do let(:user) { build(:user) } diff --git a/spec/middlewares/rack_attack_spec.rb b/spec/middlewares/rack_attack_spec.rb index 1ec71cd96..0a33cce5e 100644 --- a/spec/middlewares/rack_attack_spec.rb +++ b/spec/middlewares/rack_attack_spec.rb @@ -1,5 +1,3 @@ -require "rails_helper" - describe Rack::Attack, type: :request do let(:limit) { 5 } let(:period) { 20 } diff --git a/spec/models/administrateur_spec.rb b/spec/models/administrateur_spec.rb index f7581dc15..c1e4e3320 100644 --- a/spec/models/administrateur_spec.rb +++ b/spec/models/administrateur_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Administrateur, type: :model do let(:administration) { create(:administration) } diff --git a/spec/models/administration_spec.rb b/spec/models/administration_spec.rb index 6a8f1c35c..a2a5e8e29 100644 --- a/spec/models/administration_spec.rb +++ b/spec/models/administration_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Administration, type: :model do describe '#invite_admin' do let(:administration) { create :administration } diff --git a/spec/models/avis_spec.rb b/spec/models/avis_spec.rb index 74fb242e7..aabe056a2 100644 --- a/spec/models/avis_spec.rb +++ b/spec/models/avis_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe Avis, type: :model do let(:claimant) { create(:instructeur) } diff --git a/spec/models/bill_signature_spec.rb b/spec/models/bill_signature_spec.rb index 30157cbfe..2fdb83d36 100644 --- a/spec/models/bill_signature_spec.rb +++ b/spec/models/bill_signature_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe BillSignature, type: :model do describe 'validations' do subject(:bill_signature) { BillSignature.new } diff --git a/spec/models/champ_private_spec.rb b/spec/models/champ_private_spec.rb index c6f60362a..daa22b943 100644 --- a/spec/models/champ_private_spec.rb +++ b/spec/models/champ_private_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champ do describe '#private?' do let(:type_de_champ) { build(:type_de_champ, :private) } diff --git a/spec/models/champ_spec.rb b/spec/models/champ_spec.rb index c96f5e5d9..8d4c6b0af 100644 --- a/spec/models/champ_spec.rb +++ b/spec/models/champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champ do require 'models/champ_shared_example.rb' diff --git a/spec/models/champs/carte_champ_spec.rb b/spec/models/champs/carte_champ_spec.rb index 6beed9886..4de97465c 100644 --- a/spec/models/champs/carte_champ_spec.rb +++ b/spec/models/champs/carte_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::CarteChamp do let(:champ) { Champs::CarteChamp.new(value: value) } let(:value) { '' } diff --git a/spec/models/champs/checkbox_champ_spec.rb b/spec/models/champs/checkbox_champ_spec.rb index 9db8e9c15..cb431e6dd 100644 --- a/spec/models/champs/checkbox_champ_spec.rb +++ b/spec/models/champs/checkbox_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::CheckboxChamp do let(:checkbox) { Champs::CheckboxChamp.new(value: value) } diff --git a/spec/models/champs/decimal_number_champ_spec.rb b/spec/models/champs/decimal_number_champ_spec.rb index 7cc511b82..3684beeec 100644 --- a/spec/models/champs/decimal_number_champ_spec.rb +++ b/spec/models/champs/decimal_number_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::DecimalNumberChamp do subject { build(:champ_decimal_number, value: value).tap(&:valid?) } diff --git a/spec/models/champs/header_section_champ_spec.rb b/spec/models/champs/header_section_champ_spec.rb index 281d08f20..2e604bb5c 100644 --- a/spec/models/champs/header_section_champ_spec.rb +++ b/spec/models/champs/header_section_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::HeaderSectionChamp do describe '#section_index' do let(:types_de_champ) do diff --git a/spec/models/champs/integer_number_champ_spec.rb b/spec/models/champs/integer_number_champ_spec.rb index c61b25576..d7cb82569 100644 --- a/spec/models/champs/integer_number_champ_spec.rb +++ b/spec/models/champs/integer_number_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::IntegerNumberChamp do subject { build(:champ_integer_number, value: value).tap(&:valid?) } diff --git a/spec/models/champs/linked_drop_down_list_champ_spec.rb b/spec/models/champs/linked_drop_down_list_champ_spec.rb index 204015030..a148f7371 100644 --- a/spec/models/champs/linked_drop_down_list_champ_spec.rb +++ b/spec/models/champs/linked_drop_down_list_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Champs::LinkedDropDownListChamp do describe '#unpack_value' do let(:champ) { described_class.new(value: '["tata", "tutu"]') } diff --git a/spec/models/champs/piece_justificative_champ_spec.rb b/spec/models/champs/piece_justificative_champ_spec.rb index 506eba015..c2f691884 100644 --- a/spec/models/champs/piece_justificative_champ_spec.rb +++ b/spec/models/champs/piece_justificative_champ_spec.rb @@ -1,4 +1,19 @@ +require 'active_storage_validations/matchers' + describe Champs::PieceJustificativeChamp do + include ActiveStorageValidations::Matchers + + # TODO: once we're running on Rails 6, re-enable the PieceJustificativeChamp validator, + # and re-enable this spec. + # + # See https://github.com/betagouv/demarches-simplifiees.fr/issues/4926 + describe "validations", pending: true do + subject(:champ_pj) { build(:champ_piece_justificative) } + + it { is_expected.to validate_size_of(:piece_justificative_file).less_than(Champs::PieceJustificativeChamp::MAX_SIZE) } + it { is_expected.to validate_content_type_of(:piece_justificative_file).allowing(Champs::PieceJustificativeChamp::ACCEPTED_FORMATS) } + end + describe '#for_api' do let(:champ_pj) { create(:champ_piece_justificative) } let(:metadata) { champ_pj.piece_justificative_file.blob.metadata } diff --git a/spec/models/commentaire_spec.rb b/spec/models/commentaire_spec.rb index cbce20d7f..703a0def4 100644 --- a/spec/models/commentaire_spec.rb +++ b/spec/models/commentaire_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Commentaire do it { is_expected.to have_db_column(:email) } it { is_expected.to have_db_column(:body) } diff --git a/spec/models/concern/mail_template_concern_spec.rb b/spec/models/concern/mail_template_concern_spec.rb index 18deda804..fb9066c83 100644 --- a/spec/models/concern/mail_template_concern_spec.rb +++ b/spec/models/concern/mail_template_concern_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe MailTemplateConcern do let(:procedure) { create(:procedure) } let(:dossier) { create(:dossier, procedure: procedure) } diff --git a/spec/models/dossier_spec.rb b/spec/models/dossier_spec.rb index a003a56bc..2dab785b3 100644 --- a/spec/models/dossier_spec.rb +++ b/spec/models/dossier_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - describe Dossier do include ActiveJob::TestHelper diff --git a/spec/models/drop_down_list_spec.rb b/spec/models/drop_down_list_spec.rb index 7af28b927..45f31ab1d 100644 --- a/spec/models/drop_down_list_spec.rb +++ b/spec/models/drop_down_list_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe DropDownList do let(:dropdownlist) { create :drop_down_list, value: value } diff --git a/spec/models/etablissement_spec.rb b/spec/models/etablissement_spec.rb index bdfc65650..31ae4acef 100644 --- a/spec/models/etablissement_spec.rb +++ b/spec/models/etablissement_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Etablissement do describe '#geo_adresse' do let(:etablissement) { create(:etablissement) } diff --git a/spec/models/exercice_spec.rb b/spec/models/exercice_spec.rb index 9a906ed7a..8ecd6f349 100644 --- a/spec/models/exercice_spec.rb +++ b/spec/models/exercice_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Exercice do describe 'validations' do it { is_expected.to validate_presence_of(:ca) } diff --git a/spec/models/export_spec.rb b/spec/models/export_spec.rb index a3c75c577..f483dfb88 100644 --- a/spec/models/export_spec.rb +++ b/spec/models/export_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe Export, type: :model do describe 'validations' do let(:groupe_instructeur) { create(:groupe_instructeur) } diff --git a/spec/models/france_connect_information_spec.rb b/spec/models/france_connect_information_spec.rb index 96413d621..1abc85a30 100644 --- a/spec/models/france_connect_information_spec.rb +++ b/spec/models/france_connect_information_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe FranceConnectInformation, type: :model do describe 'validation' do context 'france_connect_particulier_id' do diff --git a/spec/models/france_connect_particulier_client_spec.rb b/spec/models/france_connect_particulier_client_spec.rb index ec7550d60..6afce5d7b 100644 --- a/spec/models/france_connect_particulier_client_spec.rb +++ b/spec/models/france_connect_particulier_client_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe FranceConnectParticulierClient do describe '#initialize' do subject { FranceConnectParticulierClient.new(code) } diff --git a/spec/models/groupe_instructeur_spec.rb b/spec/models/groupe_instructeur_spec.rb index 4a3b3ce62..6dc6d753d 100644 --- a/spec/models/groupe_instructeur_spec.rb +++ b/spec/models/groupe_instructeur_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe GroupeInstructeur, type: :model do let(:procedure) { create(:procedure) } subject { GroupeInstructeur.new(label: label, procedure: procedure) } diff --git a/spec/models/individual_spec.rb b/spec/models/individual_spec.rb index 41c7b5a2f..b678adb49 100644 --- a/spec/models/individual_spec.rb +++ b/spec/models/individual_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Individual do it { is_expected.to have_db_column(:gender) } it { is_expected.to have_db_column(:nom) } diff --git a/spec/models/instructeur_spec.rb b/spec/models/instructeur_spec.rb index e6de354c2..cdef3e0d9 100644 --- a/spec/models/instructeur_spec.rb +++ b/spec/models/instructeur_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Instructeur, type: :model do let(:admin) { create :administrateur } let!(:procedure) { create :procedure, :published, administrateur: admin } diff --git a/spec/models/invite_spec.rb b/spec/models/invite_spec.rb index 83e61935b..f6cefcecb 100644 --- a/spec/models/invite_spec.rb +++ b/spec/models/invite_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Invite do describe 'an email can be used for multiple dossier' do let(:email1) { 'plop@octo.com' } diff --git a/spec/models/procedure_overview_spec.rb b/spec/models/procedure_overview_spec.rb index 62f571e67..90815a81d 100644 --- a/spec/models/procedure_overview_spec.rb +++ b/spec/models/procedure_overview_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ProcedureOverview, type: :model do let(:procedure) { create(:procedure, libelle: 'libelle') } let(:friday) { Time.zone.local(2017, 5, 12) } # vendredi 12 mai 2017, de la semaine du 8 mai diff --git a/spec/models/procedure_presentation_spec.rb b/spec/models/procedure_presentation_spec.rb index d3985de74..cd05ba558 100644 --- a/spec/models/procedure_presentation_spec.rb +++ b/spec/models/procedure_presentation_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ProcedurePresentation do let(:procedure) { create(:procedure, :with_type_de_champ, :with_type_de_champ_private) } let(:assign_to) { create(:assign_to, procedure: procedure) } diff --git a/spec/models/procedure_spec.rb b/spec/models/procedure_spec.rb index 0d3b220df..f3dc93006 100644 --- a/spec/models/procedure_spec.rb +++ b/spec/models/procedure_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Procedure do describe 'mail templates' do subject { create(:procedure) } diff --git a/spec/models/siret_spec.rb b/spec/models/siret_spec.rb index 579c2b916..525be1bb2 100644 --- a/spec/models/siret_spec.rb +++ b/spec/models/siret_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe Siret, type: :model do subject { Siret.new(siret: siret) } diff --git a/spec/models/type_de_champ_private_spec.rb b/spec/models/type_de_champ_private_spec.rb index 161897d8e..d2520bc2a 100644 --- a/spec/models/type_de_champ_private_spec.rb +++ b/spec/models/type_de_champ_private_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe TypeDeChamp do describe '#private?' do let(:type_de_champ) { build(:type_de_champ, :private) } diff --git a/spec/models/type_de_champ_spec.rb b/spec/models/type_de_champ_spec.rb index dda8fea66..a1d3ff9fc 100644 --- a/spec/models/type_de_champ_spec.rb +++ b/spec/models/type_de_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe TypeDeChamp do require 'models/type_de_champ_shared_example' diff --git a/spec/models/types_de_champ/linked_drop_down_list_type_de_champ_spec.rb b/spec/models/types_de_champ/linked_drop_down_list_type_de_champ_spec.rb index 18c551bd4..de7323727 100644 --- a/spec/models/types_de_champ/linked_drop_down_list_type_de_champ_spec.rb +++ b/spec/models/types_de_champ/linked_drop_down_list_type_de_champ_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe TypesDeChamp::LinkedDropDownListTypeDeChamp do let(:drop_down_list) { build(:drop_down_list, value: menu_options) } let(:type_de_champ) { build(:type_de_champ_linked_drop_down_list, drop_down_list: drop_down_list) } diff --git a/spec/models/user_spec.rb b/spec/models/user_spec.rb index 084d2a6e0..323ecf2ca 100644 --- a/spec/models/user_spec.rb +++ b/spec/models/user_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe User, type: :model do describe '#after_confirmation' do let(:email) { 'mail@beta.gouv.fr' } @@ -251,7 +249,7 @@ describe User, type: :model do context 'with a dossier in instruction' do let!(:dossier_en_instruction) { create(:dossier, :en_instruction, user: user) } it 'raises' do - expect { user.delete_and_keep_track_dossiers(administration) }.to raise_error + expect { user.delete_and_keep_track_dossiers(administration) }.to raise_error(RuntimeError) end end diff --git a/spec/policies/champ_policy_spec.rb b/spec/policies/champ_policy_spec.rb index 441133bb7..b8e890577 100644 --- a/spec/policies/champ_policy_spec.rb +++ b/spec/policies/champ_policy_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ChampPolicy do let(:champ) { create(:champ_text, private: private, dossier: dossier) } let(:dossier) { create(:dossier, user: dossier_owner) } diff --git a/spec/policies/type_de_champ_policy_spec.rb b/spec/policies/type_de_champ_policy_spec.rb index e16491f37..7193aa3b5 100644 --- a/spec/policies/type_de_champ_policy_spec.rb +++ b/spec/policies/type_de_champ_policy_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe TypeDeChampPolicy do let(:procedure) { create(:procedure) } let!(:type_de_champ) { create(:type_de_champ_text, procedure: procedure) } diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index da5f1b49d..3d8f88719 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -1,7 +1,11 @@ # This file is copied to spec/ when you run 'rails generate rspec:install' +# The generated `.rspec` file contains `--require rails_helper` which will cause +# this file to always be loaded, without a need to explicitly require it in any +# files. + ENV['RAILS_ENV'] ||= 'test' -require 'spec_helper' require File.expand_path('../config/environment', __dir__) +require 'spec_helper' require 'rspec/rails' # Add additional requires below this line. Rails is not loaded until this point! @@ -20,6 +24,8 @@ require 'rspec/rails' # # Dir[Rails.root.join('spec/support/**/*.rb')].each { |f| require f } +ActiveSupport::Deprecation.silenced = true + # Checks for pending migrations before tests are run. # If you are not using ActiveRecord, you can remove this line. ActiveRecord::Migration.maintain_test_schema! @@ -27,6 +33,11 @@ ActiveRecord::Migration.maintain_test_schema! ActiveJob::Base.queue_adapter = :test RSpec.configure do |config| + # Since rspec 3.8.0, bisect uses fork to improve bisection speed. + # This however fails as soon as we're running feature tests (which uses many processes). + # Default to the :shell bisect runner, so that bisecting over feature tests works. + config.bisect_runner = :shell + # Remove this line if you're not using ActiveRecord or ActiveRecord fixtures config.fixture_path = "#{::Rails.root}/spec/fixtures" @@ -49,4 +60,11 @@ RSpec.configure do |config| # The different available types are documented in the features, such as in # https://relishapp.com/rspec/rspec-rails/docs config.infer_spec_type_from_file_location! + + config.infer_base_class_for_anonymous_controllers = false + + config.include Shoulda::Matchers::ActiveRecord, type: :model + config.include Shoulda::Matchers::ActiveModel, type: :model + config.include Devise::Test::ControllerHelpers, type: :controller + config.include Devise::Test::ControllerHelpers, type: :view end diff --git a/spec/services/administrateur_usage_statistics_service_spec.rb b/spec/services/administrateur_usage_statistics_service_spec.rb index 60de16d5e..c40e33267 100644 --- a/spec/services/administrateur_usage_statistics_service_spec.rb +++ b/spec/services/administrateur_usage_statistics_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe AdministrateurUsageStatisticsService do describe '#administrateur_stats' do let(:service) { AdministrateurUsageStatisticsService.new } diff --git a/spec/services/api_entreprise_service_spec.rb b/spec/services/api_entreprise_service_spec.rb index 192f16400..887333b33 100644 --- a/spec/services/api_entreprise_service_spec.rb +++ b/spec/services/api_entreprise_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ApiEntrepriseService do describe '#get_etablissement_params_for_siret' do before do diff --git a/spec/services/bill_signature_service_spec.rb b/spec/services/bill_signature_service_spec.rb index a6192c913..626726676 100644 --- a/spec/services/bill_signature_service_spec.rb +++ b/spec/services/bill_signature_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe BillSignatureService do describe ".grouped_unsigned_operation_until" do subject { BillSignatureService.grouped_unsigned_operation_until(date).length } diff --git a/spec/services/clamav_service_spec.rb b/spec/services/clamav_service_spec.rb index 4f843e620..2341f2229 100644 --- a/spec/services/clamav_service_spec.rb +++ b/spec/services/clamav_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ClamavService do describe '.safe_file?' do let(:path_file) { '/tmp/plop.txt' } diff --git a/spec/services/commentaire_service_spec.rb b/spec/services/commentaire_service_spec.rb index 5ab383243..1a0290ac4 100644 --- a/spec/services/commentaire_service_spec.rb +++ b/spec/services/commentaire_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe CommentaireService do include ActiveJob::TestHelper diff --git a/spec/services/dossier_search_service_spec.rb b/spec/services/dossier_search_service_spec.rb index 248b84e2e..277241445 100644 --- a/spec/services/dossier_search_service_spec.rb +++ b/spec/services/dossier_search_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe DossierSearchService do describe '#matching_dossiers_for_instructeur' do subject { liste_dossiers } diff --git a/spec/services/expired_dossiers_deletion_service_spec.rb b/spec/services/expired_dossiers_deletion_service_spec.rb index c50803963..38e241812 100644 --- a/spec/services/expired_dossiers_deletion_service_spec.rb +++ b/spec/services/expired_dossiers_deletion_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe ExpiredDossiersDeletionService do describe '#process_expired_dossiers_brouillon' do let(:draft_expiration) { 1.month + 5.days } @@ -106,14 +104,14 @@ describe ExpiredDossiersDeletionService do end context 'when a notice has been sent not so long ago' do - let(:notice_sent_at) { (warning_period - 1.day).ago } + let(:notice_sent_at) { (warning_period - 4.days).ago } it { expect { dossier.reload }.not_to raise_error } it { expect(DossierMailer).not_to have_received(:notify_brouillon_deletion) } end context 'when a notice has been sent a long time ago' do - let(:notice_sent_at) { (warning_period + 1.day).ago } + let(:notice_sent_at) { (warning_period + 4.days).ago } it { expect { dossier.reload }.to raise_error(ActiveRecord::RecordNotFound) } @@ -233,7 +231,7 @@ describe ExpiredDossiersDeletionService do end context 'when a notice has been sent not so long ago' do - let(:notice_sent_at) { (warning_period - 1.day).ago } + let(:notice_sent_at) { (warning_period - 4.days).ago } it { expect { dossier.reload }.not_to raise_error } it { expect(DossierMailer).not_to have_received(:notify_automatic_deletion_to_user) } @@ -241,7 +239,7 @@ describe ExpiredDossiersDeletionService do end context 'when a notice has been sent a long time ago' do - let(:notice_sent_at) { (warning_period + 1.day).ago } + let(:notice_sent_at) { (warning_period + 4.days).ago } it { expect { dossier.reload }.to raise_error(ActiveRecord::RecordNotFound) } diff --git a/spec/services/france_connect_service_spec.rb b/spec/services/france_connect_service_spec.rb index 561c0740d..80a611a66 100644 --- a/spec/services/france_connect_service_spec.rb +++ b/spec/services/france_connect_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe FranceConnectService do describe '.retrieve_user_informations_particulier' do let(:code) { 'plop' } diff --git a/spec/services/geojson_service_spec.rb b/spec/services/geojson_service_spec.rb index 8887d27d0..bcd9fdea3 100644 --- a/spec/services/geojson_service_spec.rb +++ b/spec/services/geojson_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe GeojsonService do let(:good_coordinates) { [ diff --git a/spec/services/ip_service_spec.rb b/spec/services/ip_service_spec.rb index 48d1c59e7..c00729bab 100644 --- a/spec/services/ip_service_spec.rb +++ b/spec/services/ip_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe IPService do describe '.ip_trusted?' do after(:each) { ENV['TRUSTED_NETWORKS'] = nil } diff --git a/spec/services/procedure_export_service_spec.rb b/spec/services/procedure_export_service_spec.rb index e54287316..1b6f87a04 100644 --- a/spec/services/procedure_export_service_spec.rb +++ b/spec/services/procedure_export_service_spec.rb @@ -1,4 +1,3 @@ -require 'spec_helper' require 'csv' describe ProcedureExportService do diff --git a/spec/services/render_partial_service_spec.rb b/spec/services/render_partial_service_spec.rb index fa5306e61..cc0df90b9 100644 --- a/spec/services/render_partial_service_spec.rb +++ b/spec/services/render_partial_service_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe RenderPartialService do let(:service) { RenderPartialService.new(controller, method) } let(:controller) { ApplicationController } diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 97fca6426..9de69b119 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1,7 +1,7 @@ # This file was generated by the `rails generate rspec:install` command. Conventionally, all # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`. -# The generated `.rspec` file contains `--require spec_helper` which will cause -# this file to always be loaded, without a need to explicitly require it in any +# The `.rspec` file contains `--require rails_helper`, which requires spec_helper.rb, +# causing this file to always be loaded, without a need to explicitly require it in any # files. # # Given that it is always loaded, you are encouraged to keep this file as @@ -17,10 +17,7 @@ # # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration -ENV['RAILS_ENV'] ||= 'test' - -require File.expand_path('../config/environment', __dir__) -require 'rspec/rails' +require 'rspec' require 'capybara/rspec' require 'capybara-screenshot/rspec' require 'capybara/email/rspec' @@ -72,12 +69,6 @@ end Dir[Rails.root.join('spec', 'support', '**', '*.rb')].each { |f| require f } Dir[Rails.root.join('spec', 'factories', '**', '*.rb')].each { |f| require f } -# Checks for pending migrations before tests are run. -# If you are not using ActiveRecord, you can remove this line. -ActiveRecord::Migration.check_pending! if defined?(ActiveRecord::Migration) - -ActiveSupport::Deprecation.silenced = true - VCR.configure do |c| c.ignore_localhost = true c.hook_into :webmock @@ -109,22 +100,8 @@ WebMock.disable_net_connect!(allow_localhost: true) RSpec.configure do |config| config.filter_run_excluding disable: true config.color = true - config.infer_spec_type_from_file_location! config.tty = true - # Since rspec 3.8.0, bisect uses fork to improve bisection speed. - # This however fails as soon as we're running feature tests (which uses many processes). - # Default to the :shell bisect runner, so that bisecting over feature tests works. - config.bisect_runner = :shell - - config.include Shoulda::Matchers::ActiveRecord, type: :model - config.include Shoulda::Matchers::ActiveModel, type: :model - config.include Shoulda::Matchers::Independent, type: :model - - config.use_transactional_fixtures = false - - config.infer_base_class_for_anonymous_controllers = false - config.run_all_when_everything_filtered = true config.filter_run :focus => true @@ -133,9 +110,6 @@ RSpec.configure do |config| # See https://github.com/rails/spring/issues/113 config.seed = srand % 0xFFFF unless ARGV.any? { |arg| arg =~ /seed/ || arg =~ /rand:/ } - config.include Devise::Test::ControllerHelpers, type: :controller - config.include Devise::Test::ControllerHelpers, type: :view - config.include FactoryBot::Syntax::Methods config.before(:each) do diff --git a/spec/support/shared_exemples_for_dossier.rb b/spec/support/shared_exemples_for_dossier.rb index a985e6aed..827d73b29 100644 --- a/spec/support/shared_exemples_for_dossier.rb +++ b/spec/support/shared_exemples_for_dossier.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - RSpec.shared_examples 'not owner of dossier' do |controller, redirect| let(:dossier_2) { create(:dossier) } diff --git a/spec/support/wait_for_ajax.rb b/spec/support/wait_for_ajax.rb deleted file mode 100644 index e57061cdb..000000000 --- a/spec/support/wait_for_ajax.rb +++ /dev/null @@ -1,9 +0,0 @@ -module WaitForAjax - def wait_for_ajax - expect(page).to have_selector('body[data-active-requests-count="0"]') - end -end - -RSpec.configure do |config| - config.include WaitForAjax, type: :feature -end diff --git a/spec/views/admin/_closed_mail_template_attestation_inconsistency_alert.html.haml_spec.rb b/spec/views/admin/_closed_mail_template_attestation_inconsistency_alert.html.haml_spec.rb index dfa51916f..642952738 100644 --- a/spec/views/admin/_closed_mail_template_attestation_inconsistency_alert.html.haml_spec.rb +++ b/spec/views/admin/_closed_mail_template_attestation_inconsistency_alert.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'admin/_closed_mail_template_attestation_inconsistency_alert.html.haml', type: :view do let(:procedure) { create(:procedure, closed_mail: closed_mail) } diff --git a/spec/views/admin/assigns/show.html.haml_spec.rb b/spec/views/admin/assigns/show.html.haml_spec.rb index 7ce691f77..382a9bdc4 100644 --- a/spec/views/admin/assigns/show.html.haml_spec.rb +++ b/spec/views/admin/assigns/show.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'admin/assigns/show.html.haml', type: :view do let(:admin) { create(:administrateur) } let(:procedure) { create :procedure, administrateur: admin } diff --git a/spec/views/admin/instructeurs/index.html.haml_spec.rb b/spec/views/admin/instructeurs/index.html.haml_spec.rb index f40405451..96d3c4c91 100644 --- a/spec/views/admin/instructeurs/index.html.haml_spec.rb +++ b/spec/views/admin/instructeurs/index.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'admin/instructeurs/index.html.haml', type: :view do let(:admin) { create(:administrateur) } diff --git a/spec/views/admin/mail_templates/edit.html.haml_spec.rb b/spec/views/admin/mail_templates/edit.html.haml_spec.rb index a381a79d9..e67d29681 100644 --- a/spec/views/admin/mail_templates/edit.html.haml_spec.rb +++ b/spec/views/admin/mail_templates/edit.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'admin/mail_templates/edit.html.haml', type: :view do let(:procedure) { create(:procedure) } let(:mail_template) { create(:received_mail, procedure: procedure) } diff --git a/spec/views/admin/procedures/show.html.haml_spec.rb b/spec/views/admin/procedures/show.html.haml_spec.rb index fe2b44b0d..15d179de5 100644 --- a/spec/views/admin/procedures/show.html.haml_spec.rb +++ b/spec/views/admin/procedures/show.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'admin/procedures/show.html.haml', type: :view do let(:closed_at) { nil } let(:procedure) { create(:procedure, :with_service, closed_at: closed_at) } diff --git a/spec/views/commencer/show.html.haml_spec.rb b/spec/views/commencer/show.html.haml_spec.rb index 3d758d664..faedd3bcf 100644 --- a/spec/views/commencer/show.html.haml_spec.rb +++ b/spec/views/commencer/show.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - RSpec.describe 'commencer/show.html.haml', type: :view do include Rails.application.routes.url_helpers diff --git a/spec/views/instructeur/dossiers/_state_button.html.haml_spec.rb b/spec/views/instructeur/dossiers/_state_button.html.haml_spec.rb index 1ee153818..e320d2464 100644 --- a/spec/views/instructeur/dossiers/_state_button.html.haml_spec.rb +++ b/spec/views/instructeur/dossiers/_state_button.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'instructeurs/dossiers/state_button.html.haml', type: :view do include DossierHelper diff --git a/spec/views/instructeur/shared/avis/list.html.haml_spec.rb b/spec/views/instructeur/shared/avis/list.html.haml_spec.rb index 155acba31..507cbf222 100644 --- a/spec/views/instructeur/shared/avis/list.html.haml_spec.rb +++ b/spec/views/instructeur/shared/avis/list.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'instructeurs/shared/avis/_list.html.haml', type: :view do before { view.extend DossierHelper } diff --git a/spec/views/instructeur_mailer/send_notifications.html.haml_spec.rb b/spec/views/instructeur_mailer/send_notifications.html.haml_spec.rb index 82575aae8..c32a37d58 100644 --- a/spec/views/instructeur_mailer/send_notifications.html.haml_spec.rb +++ b/spec/views/instructeur_mailer/send_notifications.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - describe 'instructeur_mailer/send_notifications.html.haml', type: :view do let(:instructeur) { create(:instructeur) } diff --git a/spec/views/layouts/_navbar_spec.rb b/spec/views/layouts/_navbar_spec.rb index 968aead0f..d25251c50 100644 --- a/spec/views/layouts/_navbar_spec.rb +++ b/spec/views/layouts/_navbar_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'layouts/_navbar.html.haml', type: :view do let(:administrateur) { create(:administrateur) } let(:instructeur) { create(:instructeur, administrateurs: [administrateur]) } diff --git a/spec/views/layouts/_new_header_spec.rb b/spec/views/layouts/_new_header_spec.rb index 8d896f517..89d77119e 100644 --- a/spec/views/layouts/_new_header_spec.rb +++ b/spec/views/layouts/_new_header_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'layouts/_new_header.html.haml', type: :view do let(:current_instructeur) { nil } diff --git a/spec/views/layouts/procedure_context.html.haml_spec.rb b/spec/views/layouts/procedure_context.html.haml_spec.rb index 617654577..786ab24cd 100644 --- a/spec/views/layouts/procedure_context.html.haml_spec.rb +++ b/spec/views/layouts/procedure_context.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - describe 'layouts/procedure_context.html.haml', type: :view do let(:procedure) { create(:simple_procedure, :with_service) } let(:dossier) { create(:dossier, procedure: procedure) } diff --git a/spec/views/new_administrateur/procedures/edit.html.haml_spec.rb b/spec/views/new_administrateur/procedures/edit.html.haml_spec.rb index 89ed5339b..2f9c83785 100644 --- a/spec/views/new_administrateur/procedures/edit.html.haml_spec.rb +++ b/spec/views/new_administrateur/procedures/edit.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'new_administrateur/procedures/edit.html.haml' do let(:logo) { Rack::Test::UploadedFile.new("./spec/fixtures/files/logo_test_procedure.png", 'image/png') } let(:procedure) { create(:procedure, logo: logo, lien_site_web: 'http://some.website') } diff --git a/spec/views/shared/attachment/_show.html.haml_spec.rb b/spec/views/shared/attachment/_show.html.haml_spec.rb index 81cf9024d..0cbd1bae5 100644 --- a/spec/views/shared/attachment/_show.html.haml_spec.rb +++ b/spec/views/shared/attachment/_show.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - describe 'shared/attachment/_show.html.haml', type: :view do let(:champ) { create(:champ_piece_justificative) } let(:virus_scan_result) { nil } diff --git a/spec/views/shared/attachment/_update.html.haml_spec.rb b/spec/views/shared/attachment/_update.html.haml_spec.rb index a98a30b0a..a53a22856 100644 --- a/spec/views/shared/attachment/_update.html.haml_spec.rb +++ b/spec/views/shared/attachment/_update.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'rails_helper' - describe 'shared/attachment/_update.html.haml', type: :view do let(:champ) { build(:champ_piece_justificative, dossier: create(:dossier)) } let(:attached_file) { champ.piece_justificative_file } diff --git a/spec/views/users/dossiers/brouillon.html.haml_spec.rb b/spec/views/users/dossiers/brouillon.html.haml_spec.rb index 1d66d554f..83a15da28 100644 --- a/spec/views/users/dossiers/brouillon.html.haml_spec.rb +++ b/spec/views/users/dossiers/brouillon.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'users/dossiers/brouillon.html.haml', type: :view do let(:procedure) { create(:procedure, :with_type_de_champ, :with_notice, :with_service) } let(:dossier) { create(:dossier, state: Dossier.states.fetch(:brouillon), procedure: procedure) } diff --git a/spec/views/users/dossiers/demande.html.haml_spec.rb b/spec/views/users/dossiers/demande.html.haml_spec.rb index b48a3e5ae..0a46903d4 100644 --- a/spec/views/users/dossiers/demande.html.haml_spec.rb +++ b/spec/views/users/dossiers/demande.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'users/dossiers/demande.html.haml', type: :view do let(:procedure) { create(:procedure, :published, :with_type_de_champ, :with_type_de_champ_private) } let(:dossier) { create(:dossier, :en_construction, :with_entreprise, procedure: procedure) } diff --git a/spec/views/users/dossiers/etablissement.html.haml_spec.rb b/spec/views/users/dossiers/etablissement.html.haml_spec.rb index 7f74e05f1..a7d2cc3d7 100644 --- a/spec/views/users/dossiers/etablissement.html.haml_spec.rb +++ b/spec/views/users/dossiers/etablissement.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'users/dossiers/etablissement.html.haml', type: :view do let(:etablissement) { create(:etablissement, :with_exercices) } let(:dossier) { create(:dossier, etablissement: etablissement) } diff --git a/spec/views/users/dossiers/identite.html.haml_spec.rb b/spec/views/users/dossiers/identite.html.haml_spec.rb index 2f01ef41c..62d685dec 100644 --- a/spec/views/users/dossiers/identite.html.haml_spec.rb +++ b/spec/views/users/dossiers/identite.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'users/dossiers/identite.html.haml', type: :view do let(:procedure) { create(:simple_procedure, :for_individual) } let(:dossier) { create(:dossier, :with_service, state: Dossier.states.fetch(:brouillon), procedure: procedure) } diff --git a/spec/views/users/dossiers/index.html.haml_spec.rb b/spec/views/users/dossiers/index.html.haml_spec.rb index e908b5678..ff91ccce5 100644 --- a/spec/views/users/dossiers/index.html.haml_spec.rb +++ b/spec/views/users/dossiers/index.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'users/dossiers/index.html.haml', type: :view do let(:user) { create(:user) } let(:dossier_brouillon) { create(:dossier, state: Dossier.states.fetch(:brouillon), user: user) } diff --git a/spec/views/users/dossiers/show.html.haml_spec.rb b/spec/views/users/dossiers/show.html.haml_spec.rb index 30f6e8d72..821cfbb27 100644 --- a/spec/views/users/dossiers/show.html.haml_spec.rb +++ b/spec/views/users/dossiers/show.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'users/dossiers/show.html.haml', type: :view do let(:dossier) { create(:dossier, :en_construction) } diff --git a/spec/views/users/dossiers/siret.html.haml_spec.rb b/spec/views/users/dossiers/siret.html.haml_spec.rb index 23890b1e7..e1068ef30 100644 --- a/spec/views/users/dossiers/siret.html.haml_spec.rb +++ b/spec/views/users/dossiers/siret.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'users/dossiers/siret.html.haml', type: :view do let(:dossier) { create(:dossier) } diff --git a/spec/views/users/sessions/new.html.haml_spec.rb b/spec/views/users/sessions/new.html.haml_spec.rb index 3ffddef9f..9b3da052d 100644 --- a/spec/views/users/sessions/new.html.haml_spec.rb +++ b/spec/views/users/sessions/new.html.haml_spec.rb @@ -1,5 +1,3 @@ -require 'spec_helper' - describe 'users/sessions/new.html.haml', type: :view do let(:dossier) { create :dossier } diff --git a/yarn.lock b/yarn.lock index c2b25f432..cf106e02f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3,11 +3,11 @@ "@babel/code-frame@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0.tgz#06e2ab19bdb535385559aabb5ba59729482800f8" - integrity sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA== + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.8.3.tgz#33e25903d7481181534e12ec0a25f16b6fcf419e" + integrity sha512-a9gxpmdXtZEInkCSHUJDLHZVBgb1QS0jhss4cPP93EW7s+uC5bikET2twEF3KV+7rDblJcmNvTR7VJejqd2C2g== dependencies: - "@babel/highlight" "^7.0.0" + "@babel/highlight" "^7.8.3" "@babel/code-frame@^7.5.5": version "7.5.5" @@ -265,6 +265,11 @@ dependencies: "@babel/types" "^7.7.4" +"@babel/helper-validator-identifier@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.9.0.tgz#ad53562a7fc29b3b9a91bbf7d10397fd146346ed" + integrity sha512-6G8bQKjOh+of4PV/ThDm/rRqlU7+IGoJuofpagU5GlEl29Vv0RGqqt86ZGRV8ZuSOY3o+8yXl5y782SMcG7SHw== + "@babel/helper-wrap-function@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.7.4.tgz#37ab7fed5150e22d9d7266e830072c0cdd8baace" @@ -284,13 +289,13 @@ "@babel/traverse" "^7.7.4" "@babel/types" "^7.7.4" -"@babel/highlight@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0.tgz#f710c38c8d458e6dd9a201afb637fcb781ce99e4" - integrity sha512-UFMC4ZeFC48Tpvj7C8UgLvtkaUuovQX+5xNWrsIoMG8o2z+XFKjKaN9iVmS84dPwVN00W4wPmqvYoZF3EGAsfw== +"@babel/highlight@^7.0.0", "@babel/highlight@^7.8.3": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.9.0.tgz#4e9b45ccb82b79607271b2979ad82c7b68163079" + integrity sha512-lJZPilxX7Op3Nv/2cvFdnlepPXDxi29wxteT57Q965oc5R9v86ztx0jfxVrTcBk8C2kcPkkDa2Z4T3ZsPPVWsQ== dependencies: + "@babel/helper-validator-identifier" "^7.9.0" chalk "^2.0.0" - esutils "^2.0.2" js-tokens "^4.0.0" "@babel/parser@^7.0.0", "@babel/parser@^7.4.0", "@babel/parser@^7.4.3": @@ -1032,6 +1037,11 @@ dependencies: "@turf/helpers" "6.x" +"@types/color-name@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@types/color-name/-/color-name-1.1.1.tgz#1c1261bbeaa10a8055bbc5d8ab84b7b2afc846a0" + integrity sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ== + "@types/events@*": version "3.0.0" resolved "https://registry.yarnpkg.com/@types/events/-/events-3.0.0.tgz#2862f3f58a9a7f7c3e78d79f130dd4d71c25c2a7" @@ -1243,10 +1253,10 @@ accepts@~1.3.7: mime-types "~2.1.24" negotiator "0.6.2" -acorn-jsx@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.1.0.tgz#294adb71b57398b0680015f0a38c563ee1db5384" - integrity sha512-tMUqwBWfLFbJbizRmEcWSLw6HnFzfdJs2sOJEOwwtVPMoH/0Ay+E703oZz78VSXZiiDcZrQ5XKjPIUQixhmgVw== +acorn-jsx@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.2.0.tgz#4c66069173d6fdd68ed85239fc256226182b2ebe" + integrity sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ== acorn-walk@^6.1.1: version "6.2.0" @@ -1258,10 +1268,10 @@ acorn@^6.0.7, acorn@^6.2.1: resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.4.1.tgz#531e58ba3f51b9dacb9a6646ca4debf5b14ca474" integrity sha512-ZVA9k326Nwrj3Cj9jlh3wGFutC2ZornPNARZwsNYqQYgN0EsV2d53w5RN/co65Ohn4sUAUtb1rSUAOD6XN9idA== -acorn@^7.1.0: - version "7.1.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.1.0.tgz#949d36f2c292535da602283586c2477c57eb2d6c" - integrity sha512-kL5CuoXA/dgxlBbVrflsflzQ3PAas7RYZB52NOm/6839iVYJgKMJ3cQJD+t2i5+qFa8h3MDpEOJiS64E8JLnSQ== +acorn@^7.1.1: + version "7.1.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.1.1.tgz#e35668de0b402f359de515c5482a1ab9f89a69bf" + integrity sha512-add7dgA5ppRPxCFJoAGfMDi7PIBXq1RtGo7BhbLaxwrXPOmw8gq48Y9ozT01hUKy9byMjlR20EJhu5zlkErEkg== aggregate-error@^3.0.0: version "3.0.1" @@ -1286,7 +1296,7 @@ ajv-keywords@^3.4.1: resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.4.1.tgz#ef916e271c64ac12171fd8384eaae6b2345854da" integrity sha512-RO1ibKvd27e6FEShVFfPALuHI3WjSVNeK5FIsmme/LYRNxjKuNj+Dt7bucLa6NdSv3JcVTyMlm9kGR84z1XpaQ== -ajv@^6.1.0, ajv@^6.5.5, ajv@^6.9.1: +ajv@^6.1.0, ajv@^6.5.5: version "6.10.0" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.0.tgz#90d0d54439da587cd7e843bfb7045f50bd22bdf1" integrity sha512-nffhOpkymDECQyR0mnsUtoCE8RlX38G0rYP+wgLWFyZuUyuuojSSvi/+euOiQBIn63whYwYVIIH1TvE3tu4OEg== @@ -1296,7 +1306,17 @@ ajv@^6.1.0, ajv@^6.5.5, ajv@^6.9.1: json-schema-traverse "^0.4.1" uri-js "^4.2.2" -ajv@^6.10.0, ajv@^6.10.2: +ajv@^6.10.0: + version "6.12.0" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.0.tgz#06d60b96d87b8454a5adaba86e7854da629db4b7" + integrity sha512-D6gFiFA0RRLyUbvijN74DWAjXSFxWKaWP7mldxkVhyhAV3+SWA9HEJPHQ2c9soIeTFJqcSdFDGFgdqs1iUU2Hw== + dependencies: + fast-deep-equal "^3.1.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" + +ajv@^6.10.2: version "6.10.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.2.tgz#d3cea04d6b017b2894ad69040fec8b623eb4bd52" integrity sha512-TXtUUEYHuaTEbLZWIKUr5pmBuhDLy+8KYtPYdcV8qC+pOZL+NKqYwvWSRrVXHn+ZmRRAu8vJTAznH7Oag6RVRw== @@ -1341,11 +1361,11 @@ ansi-escapes@^3.1.0: integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== ansi-escapes@^4.2.1: - version "4.2.1" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.2.1.tgz#4dccdb846c3eee10f6d64dea66273eab90c37228" - integrity sha512-Cg3ymMAdN10wOk/VYfLV7KCQyv7EDirJ64500sU7n9UlmioEtDuU5Gd+hj73hXSU/ex7tHJSssmyftDdkMLO8Q== + version "4.3.1" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.1.tgz#a5c47cc43181f1f38ffd7076837700d395522a61" + integrity sha512-JWF7ocqNrp8u9oqpgV+wH5ftbt+cfvv+PTjOvKLT3AdYly/LmORARfEVT1iyjwN+4MqE5UmVKoAdIBqeoCHgLA== dependencies: - type-fest "^0.5.2" + type-fest "^0.11.0" ansi-gray@^0.1.1: version "0.1.1" @@ -1381,6 +1401,11 @@ ansi-regex@^4.1.0: resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" integrity sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg== +ansi-regex@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.0.tgz#388539f55179bf39339c81af30a654d69f87cb75" + integrity sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg== + ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" @@ -1393,6 +1418,14 @@ ansi-styles@^3.2.0, ansi-styles@^3.2.1: dependencies: color-convert "^1.9.0" +ansi-styles@^4.1.0: + version "4.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.2.1.tgz#90ae75c424d008d2624c5bf29ead3177ebfcf359" + integrity sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA== + dependencies: + "@types/color-name" "^1.1.1" + color-convert "^2.0.1" + ansi-wrap@0.1.0, ansi-wrap@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" @@ -2128,6 +2161,14 @@ chalk@^1.1.1: strip-ansi "^3.0.0" supports-color "^2.0.0" +chalk@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-3.0.0.tgz#3f73c2bf526591f574cc492c51e2456349f844e4" + integrity sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + chardet@^0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" @@ -2347,12 +2388,19 @@ color-convert@^1.9.0, color-convert@^1.9.1: dependencies: color-name "1.1.3" +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== + dependencies: + color-name "~1.1.4" + color-name@1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= -color-name@^1.0.0: +color-name@^1.0.0, color-name@~1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== @@ -3498,12 +3546,12 @@ eslint@^6.7.2: v8-compile-cache "^2.0.3" espree@^6.1.2: - version "6.1.2" - resolved "https://registry.yarnpkg.com/espree/-/espree-6.1.2.tgz#6c272650932b4f91c3714e5e7b5f5e2ecf47262d" - integrity sha512-2iUPuuPP+yW1PZaMSDM9eyVf8D5P0Hi8h83YtZ5bPc/zHYjII5khoixIUTMO794NOY8F/ThF1Bo8ncZILarUTA== + version "6.2.1" + resolved "https://registry.yarnpkg.com/espree/-/espree-6.2.1.tgz#77fc72e1fd744a2052c20f38a5b575832e82734a" + integrity sha512-ysCxRQY3WaXJz9tdbWOwuWr5Y/XrPTGX9Kiz3yoUXwW0VZ4w30HTkQLaGx/+ttFjF8i+ACbArnB4ce68a9m5hw== dependencies: - acorn "^7.1.0" - acorn-jsx "^5.1.0" + acorn "^7.1.1" + acorn-jsx "^5.2.0" eslint-visitor-keys "^1.1.0" esprima@^4.0.0: @@ -3512,11 +3560,11 @@ esprima@^4.0.0: integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== esquery@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" - integrity sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA== + version "1.2.0" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.2.0.tgz#a010a519c0288f2530b3404124bfb5f02e9797fe" + integrity sha512-weltsSqdeWIX9G2qQZz7KlTRJdkkOCTPgLYJUz1Hacf48R4YOwGPHO3+ORfWedqJKbq5WQmsgK90n+pFLIKt/Q== dependencies: - estraverse "^4.0.0" + estraverse "^5.0.0" esrecurse@^4.1.0: version "4.2.1" @@ -3525,16 +3573,26 @@ esrecurse@^4.1.0: dependencies: estraverse "^4.1.0" -estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1: - version "4.2.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" - integrity sha1-De4/7TH81GlhjOc0IJn8GvoL2xM= +estraverse@^4.1.0, estraverse@^4.1.1: + version "4.3.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" + integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== -esutils@^2.0.0, esutils@^2.0.2: +estraverse@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.0.0.tgz#ac81750b482c11cca26e4b07e83ed8f75fbcdc22" + integrity sha512-j3acdrMzqrxmJTNj5dbr1YbjacrYgAxVMeF0gK16E3j494mOe7xygM/ZLIguEQ0ETwAg2hlJCtHRGav+y0Ny5A== + +esutils@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" integrity sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs= +esutils@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" + integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== + etag@~1.8.1: version "1.8.1" resolved "https://registry.yarnpkg.com/etag/-/etag-1.8.1.tgz#41ae2eeb65efa62268aebfea83ac7d79299b0887" @@ -3675,9 +3733,9 @@ extend@^3.0.0, extend@~3.0.2: integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== external-editor@^3.0.3: - version "3.0.3" - resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.0.3.tgz#5866db29a97826dbe4bf3afd24070ead9ea43a27" - integrity sha512-bn71H9+qWoOQKyZDo25mOMVpSmXROAsTJVVVYzrrtol3d4y+AsKjf4Iwl2Q+IuT0kFSQ1qo166UuIwqYq7mGnA== + version "3.1.0" + resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.1.0.tgz#cb03f740befae03ea4d283caed2741a83f335495" + integrity sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew== dependencies: chardet "^0.7.0" iconv-lite "^0.4.24" @@ -3722,15 +3780,20 @@ fast-deep-equal@^2.0.1: resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz#7b05218ddf9667bf7f370bf7fdb2cb15fdd0aa49" integrity sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk= +fast-deep-equal@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz#545145077c501491e33b15ec408c294376e94ae4" + integrity sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA== + fast-diff@^1.1.2: version "1.2.0" resolved "https://registry.yarnpkg.com/fast-diff/-/fast-diff-1.2.0.tgz#73ee11982d86caaf7959828d519cfe927fac5f03" integrity sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w== fast-json-stable-stringify@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" - integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I= + version "2.1.0" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" + integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== fast-levenshtein@~2.0.6: version "2.0.6" @@ -3764,9 +3827,9 @@ figgy-pudding@^3.5.1: integrity sha512-vNKxJHTEKNThjfrdJwHc7brvM6eVevuO5nTj6ez8ZQ1qbXTvGthucRF7S4vf2cr71QVnT70V34v0S1DyQsti0w== figures@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/figures/-/figures-3.1.0.tgz#4b198dd07d8d71530642864af2d45dd9e459c4ec" - integrity sha512-ravh8VRXqHuMvZt/d8GblBeqDMkdJMBdv/2KntFH+ra5MXkO7nxNKpzQ3n6QD/2da1kH0aWmNISdvhM7gl2gVg== + version "3.2.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-3.2.0.tgz#625c18bd293c604dc4a8ddb2febf0c88341746af" + integrity sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg== dependencies: escape-string-regexp "^1.0.5" @@ -3879,9 +3942,9 @@ flat-cache@^2.0.1: write "1.0.3" flatted@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.0.tgz#55122b6536ea496b4b44893ee2608141d10d9916" - integrity sha512-R+H8IZclI8AAkSBRQJLVOsxwAoHd6WC40b4QTNWIjzAa6BXOBfQcM587MXDTVPeYaopFNWHUFLx7eNmHDSxMWg== + version "2.0.2" + resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.2.tgz#4575b21e2bcee7434aa9be662f4b7b5f9c2b5138" + integrity sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA== flatted@^2.0.1: version "2.0.1" @@ -4112,9 +4175,9 @@ glob-parent@^3.1.0: path-dirname "^1.0.0" glob-parent@^5.0.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.0.tgz#5f4c1d1e748d30cd73ad2944b3577a81b081e8c2" - integrity sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw== + version "5.1.1" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.1.tgz#b6c1ef417c4e5663ea498f1c45afac6916bbc229" + integrity sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ== dependencies: is-glob "^4.0.1" @@ -4146,10 +4209,10 @@ glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@~7.1.1: once "^1.3.0" path-is-absolute "^1.0.0" -glob@^7.1.3, glob@^7.1.4: - version "7.1.4" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" - integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== +glob@^7.1.3, glob@^7.1.6: + version "7.1.6" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.6.tgz#141f33b81a7c2492e125594307480c46679278a6" + integrity sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" @@ -4158,10 +4221,10 @@ glob@^7.1.3, glob@^7.1.4: once "^1.3.0" path-is-absolute "^1.0.0" -glob@^7.1.6: - version "7.1.6" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.6.tgz#141f33b81a7c2492e125594307480c46679278a6" - integrity sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA== +glob@^7.1.4: + version "7.1.4" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" + integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" @@ -4212,9 +4275,9 @@ globals@^11.1.0: integrity sha512-WHq43gS+6ufNOEqlrDBxVEbb8ntfXrfAUU2ZOpCxrBdGKW3gyv8mCxAfIBD0DroPKGrJ2eSsXsLtY9MPntsyTw== globals@^12.1.0: - version "12.3.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-12.3.0.tgz#1e564ee5c4dded2ab098b0f88f24702a3c56be13" - integrity sha512-wAfjdLgFsPZsklLJvOBUBmzYE8/CwhEqSBEMRXA3qxIiNtyqvjYurAtIfDh6chlEPUfmTY3MnZh5Hfh4q0UlIw== + version "12.4.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-12.4.0.tgz#a18813576a41b00a24a97e7f815918c2e19925f8" + integrity sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg== dependencies: type-fest "^0.8.1" @@ -4352,6 +4415,11 @@ has-flag@^3.0.0: resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== + has-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" @@ -4618,15 +4686,7 @@ import-fresh@^2.0.0: caller-path "^2.0.0" resolve-from "^3.0.0" -import-fresh@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.0.0.tgz#a3d897f420cab0e671236897f75bc14b4885c390" - integrity sha512-pOnA9tfM3Uwics+SaBLCNyZZZbK+4PTu0OPZtLlMIrv17EdBoC15S9Kn8ckJ9TZTyKb3ywNE5y1yeDxxGA7nTQ== - dependencies: - parent-module "^1.0.0" - resolve-from "^4.0.0" - -import-fresh@^3.1.0: +import-fresh@^3.0.0, import-fresh@^3.1.0: version "3.2.1" resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.2.1.tgz#633ff618506e793af5ac91bf48b72677e15cbe66" integrity sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ== @@ -4698,20 +4758,20 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@2.0.3, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" - integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4= +inherits@2, inherits@2.0.4: + version "2.0.4" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== inherits@2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.1.tgz#b17d08d326b4423e568eff719f91b0b1cbdf69f1" integrity sha1-sX0I0ya0Qj5Wjv9xn5GwscvfafE= -inherits@2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" - integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== +inherits@2.0.3, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" + integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4= ini@^1.3.4, ini@^1.3.5, ini@~1.3.0: version "1.3.5" @@ -4719,22 +4779,22 @@ ini@^1.3.4, ini@^1.3.5, ini@~1.3.0: integrity sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw== inquirer@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-7.0.0.tgz#9e2b032dde77da1db5db804758b8fea3a970519a" - integrity sha512-rSdC7zelHdRQFkWnhsMu2+2SO41mpv2oF2zy4tMhmiLWkcKbOAs87fWAJhVXttKVwhdZvymvnuM95EyEXg2/tQ== + version "7.1.0" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-7.1.0.tgz#1298a01859883e17c7264b82870ae1034f92dd29" + integrity sha512-5fJMWEmikSYu0nv/flMc475MhGbB7TSPd/2IpFV4I4rMklboCH2rQjYY5kKiYGHqUF9gvaambupcJFFG9dvReg== dependencies: ansi-escapes "^4.2.1" - chalk "^2.4.2" + chalk "^3.0.0" cli-cursor "^3.1.0" cli-width "^2.0.0" external-editor "^3.0.3" figures "^3.0.0" lodash "^4.17.15" mute-stream "0.0.8" - run-async "^2.2.0" - rxjs "^6.4.0" + run-async "^2.4.0" + rxjs "^6.5.3" string-width "^4.1.0" - strip-ansi "^5.1.0" + strip-ansi "^6.0.0" through "^2.3.6" internal-ip@^4.3.0: @@ -5448,12 +5508,12 @@ lodash.uniq@^4.5.0: resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M= -lodash@^4.0.0, lodash@^4.17.10, lodash@^4.17.11, lodash@^4.17.5, lodash@~4.17.10: +lodash@^4.0.0, lodash@^4.17.10, lodash@^4.17.5, lodash@~4.17.10: version "4.17.14" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.14.tgz#9ce487ae66c96254fe20b599f21b6816028078ba" integrity sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw== -lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15: +lodash@^4.17.11, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15: version "4.17.15" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548" integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A== @@ -5716,6 +5776,11 @@ minimist@^1.1.3, minimist@^1.2.0: resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= +minimist@^1.2.5: + version "1.2.5" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" + integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== + minipass-collect@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/minipass-collect/-/minipass-collect-1.0.2.tgz#22b813bf745dc6edba2576b940022ad6edc8c617" @@ -5783,13 +5848,20 @@ mixin-deep@^1.2.0: for-in "^1.0.2" is-extendable "^1.0.1" -"mkdirp@>=0.5 0", mkdirp@^0.5, mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@~0.5.1: +"mkdirp@>=0.5 0", mkdirp@^0.5, mkdirp@^0.5.0, mkdirp@~0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= dependencies: minimist "0.0.8" +mkdirp@^0.5.1: + version "0.5.4" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.4.tgz#fd01504a6797ec5c9be81ff43d204961ed64a512" + integrity sha512-iG9AK/dJLtJ0XNgTuDbSyNS3zECqDlAhnQW4CsNxBG3LQJBbHmRX1egw39DmtOdCAqY+dKXV+sgPgilNWUKMVw== + dependencies: + minimist "^1.2.5" + move-concurrently@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/move-concurrently/-/move-concurrently-1.0.1.tgz#be2c005fda32e0b29af1f05d7c4b33214c701f92" @@ -5807,11 +5879,16 @@ ms@2.0.0: resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= -ms@2.1.1, ms@^2.1.1: +ms@2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.1.tgz#30a5864eb3ebb0a66f2ebe6d727af06a09d86e0a" integrity sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg== +ms@^2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + multicast-dns-service-types@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/multicast-dns-service-types/-/multicast-dns-service-types-1.1.0.tgz#899f11d9686e5e05cb91b35d5f0e63b773cfc901" @@ -7924,10 +8001,10 @@ ripemd160@^2.0.0, ripemd160@^2.0.1: hash-base "^3.0.0" inherits "^2.0.1" -run-async@^2.2.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" - integrity sha1-A3GrSuC91yDUFm19/aZP96RFpsA= +run-async@^2.4.0: + version "2.4.0" + resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.4.0.tgz#e59054a5b86876cfae07f431d18cbaddc594f1e8" + integrity sha512-xJTbh/d7Lm7SBhc1tNvTpeCHaEzoyxPrqNlvSdMfBTYwaY++UJFyXUOxAtsRUXjlqOfj8luNaR9vjCh4KeV+pg== dependencies: is-promise "^2.1.0" @@ -7938,10 +8015,10 @@ run-queue@^1.0.0, run-queue@^1.0.3: dependencies: aproba "^1.1.1" -rxjs@^6.4.0: - version "6.5.1" - resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.5.1.tgz#f7a005a9386361921b8524f38f54cbf80e5d08f4" - integrity sha512-y0j31WJc83wPu31vS1VlAFW5JGrnGC+j+TtGAa1fRQphy48+fDYiDmX8tjGloToEsMkxnouOg/1IzXGKkJnZMg== +rxjs@^6.5.3: + version "6.5.4" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.5.4.tgz#e0777fe0d184cec7872df147f303572d414e211c" + integrity sha512-naMQXcgEo3csAEGvw/NydRA0fuS2nDZJiw1YUWFKU7aPPAPGZEsD4Iimit96qwCieH6y614MCLYwdkrWx7z/7Q== dependencies: tslib "^1.9.0" @@ -8046,7 +8123,7 @@ selfsigned@^1.10.7: dependencies: node-forge "0.9.0" -"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0, semver@^5.5.1, semver@^5.6.0: +"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.1, semver@^5.6.0: version "5.7.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz#790a7cf6fea5459bac96110b29b60412dc8ff96b" integrity sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA== @@ -8056,6 +8133,11 @@ semver@7.0.0: resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== +semver@^5.5.0: + version "5.7.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" + integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + semver@^6.0.0, semver@^6.1.2, semver@^6.3.0: version "6.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" @@ -8185,11 +8267,16 @@ sigmund@^1.0.1: resolved "https://registry.yarnpkg.com/sigmund/-/sigmund-1.0.1.tgz#3ff21f198cad2175f9f3b781853fd94d0d19b590" integrity sha1-P/IfGYytIXX587eBhT/ZTQ0ZtZA= -signal-exit@^3.0.0, signal-exit@^3.0.2: +signal-exit@^3.0.0: version "3.0.2" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0= +signal-exit@^3.0.2: + version "3.0.3" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.3.tgz#a1410c2edd8f077b08b4e253c8eacfcaf057461c" + integrity sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA== + simple-swizzle@^0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/simple-swizzle/-/simple-swizzle-0.2.2.tgz#a4da6b635ffcccca33f70d17cb92592de95e557a" @@ -8508,13 +8595,13 @@ string-width@^3.0.0, string-width@^3.1.0: strip-ansi "^5.1.0" string-width@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.1.0.tgz#ba846d1daa97c3c596155308063e075ed1c99aff" - integrity sha512-NrX+1dVVh+6Y9dnQ19pR0pP4FiEIlUvdTGn8pw6CKTNq5sgib2nIhmUNT5TAmhWmvKr3WcxBcP3E8nWezuipuQ== + version "4.2.0" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.0.tgz#952182c46cc7b2c313d1596e623992bd163b72b5" + integrity sha512-zUz5JD+tgqtuDjMhwIg5uFVV3dtqZ9yQJlZVfq4I01/K5Paj5UHj7VyrQOJvzawSVlKpObApbfD0Ed6yJc+1eg== dependencies: emoji-regex "^8.0.0" is-fullwidth-code-point "^3.0.0" - strip-ansi "^5.2.0" + strip-ansi "^6.0.0" string.prototype.trimleft@^2.1.1: version "2.1.1" @@ -8567,6 +8654,13 @@ strip-ansi@^5.0.0, strip-ansi@^5.1.0, strip-ansi@^5.2.0: dependencies: ansi-regex "^4.1.0" +strip-ansi@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.0.tgz#0b1571dd7669ccd4f3e06e14ef1eed26225ae532" + integrity sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w== + dependencies: + ansi-regex "^5.0.0" + strip-bom@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" @@ -8632,6 +8726,13 @@ supports-color@^5.3.0: dependencies: has-flag "^3.0.0" +supports-color@^7.1.0: + version "7.1.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.1.0.tgz#68e32591df73e25ad1c4b49108a2ec507962bfd1" + integrity sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g== + dependencies: + has-flag "^4.0.0" + svgo@^1.0.0: version "1.2.2" resolved "https://registry.yarnpkg.com/svgo/-/svgo-1.2.2.tgz#0253d34eccf2aed4ad4f283e11ee75198f9d7316" @@ -8653,12 +8754,12 @@ svgo@^1.0.0: util.promisify "~1.0.0" table@^5.2.3: - version "5.2.3" - resolved "https://registry.yarnpkg.com/table/-/table-5.2.3.tgz#cde0cc6eb06751c009efab27e8c820ca5b67b7f2" - integrity sha512-N2RsDAMvDLvYwFcwbPyF3VmVSSkuF+G1e+8inhBLtHpvwXGw4QRPEZhihQNeEN0i1up6/f6ObCJXNdlRG3YVyQ== + version "5.4.6" + resolved "https://registry.yarnpkg.com/table/-/table-5.4.6.tgz#1292d19500ce3f86053b05f0e8e7e4a3bb21079e" + integrity sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug== dependencies: - ajv "^6.9.1" - lodash "^4.17.11" + ajv "^6.10.2" + lodash "^4.17.14" slice-ansi "^2.1.0" string-width "^3.0.0" @@ -8903,7 +9004,12 @@ ts-pnp@^1.1.2: resolved "https://registry.yarnpkg.com/ts-pnp/-/ts-pnp-1.1.2.tgz#be8e4bfce5d00f0f58e0666a82260c34a57af552" integrity sha512-f5Knjh7XCyRIzoC/z1Su1yLLRrPrFCgtUAh/9fCSP6NKbATwpOL1+idQVXQokK9GRFURn/jYPGPfegIctwunoA== -tslib@^1.9.0, tslib@^1.9.3: +tslib@^1.9.0: + version "1.11.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.11.1.tgz#eb15d128827fbee2841549e171f45ed338ac7e35" + integrity sha512-aZW88SY8kQbU7gpV19lN24LtXh/yD4ZZg6qieAJDDg+YBsJcSmLGK9QpnUjAKVG/xefmvJGd1WUmfpT/g6AJGA== + +tslib@^1.9.3: version "1.9.3" resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.3.tgz#d7e4dd79245d85428c4d7e4822a79917954ca286" integrity sha512-4krF8scpejhaOgqzBEcGM7yDIEfi0/8+8zDRZhNZZ2kjmHJ4hv3zCbQWxoJGz1iw5U0Jl0nma13xzHXcncMavQ== @@ -8949,10 +9055,10 @@ type-check@~0.3.2: dependencies: prelude-ls "~1.1.2" -type-fest@^0.5.2: - version "0.5.2" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.5.2.tgz#d6ef42a0356c6cd45f49485c3b6281fc148e48a2" - integrity sha512-DWkS49EQKVX//Tbupb9TFa19c7+MK1XmzkrZUR8TAktmE/DizXoaoJV6TZ/tSIPXipqNiRI6CyAe7x69Jb6RSw== +type-fest@^0.11.0: + version "0.11.0" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.11.0.tgz#97abf0872310fed88a5c466b25681576145e33f1" + integrity sha512-OdjXJxnCN1AvyLSzeKIgXTXxV+99ZuXl3Hpo9XpJAv9MBcHrrJOQ5kV7ypXOuQie+AmWG25hLbiKdwYTifzcfQ== type-fest@^0.8.1: version "0.8.1"