sorbet-rails 0.7.4 → 0.7.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (357) hide show
  1. checksums.yaml +4 -4
  2. data/.github/dependabot.yml +7 -0
  3. data/.github/workflows/ci-master.yml +28 -0
  4. data/.github/workflows/ci.yml +26 -0
  5. data/.github/workflows/publish-gem.yml +21 -0
  6. data/CONTRIBUTING.md +1 -2
  7. data/Gemfile +7 -9
  8. data/README.md +7 -3
  9. data/Rakefile +13 -24
  10. data/lib/sorbet-rails/active_record_rbi_formatter.rb +12 -9
  11. data/lib/sorbet-rails/dependent_gem_rbis/activerecord.rbi +4 -0
  12. data/lib/sorbet-rails/dependent_gem_rbis/parlour.rbi +1 -1
  13. data/lib/sorbet-rails/gem_plugins/aasm_plugin.rb +50 -0
  14. data/lib/sorbet-rails/gem_plugins/money_rails_plugin.rb +76 -0
  15. data/lib/sorbet-rails/job_rbi_formatter.rb +1 -1
  16. data/lib/sorbet-rails/model_plugins/active_record_serialized_attribute.rb +3 -2
  17. data/lib/sorbet-rails/model_plugins/base.rb +8 -1
  18. data/lib/sorbet-rails/model_plugins/custom_finder_methods.rb +1 -1
  19. data/lib/sorbet-rails/model_plugins/plugins.rb +6 -0
  20. data/lib/sorbet-rails/railtie.rb +1 -1
  21. data/lib/sorbet-rails/routes_rbi_formatter.rb +8 -0
  22. data/lib/sorbet-rails/tasks/rails_rbi.rake +12 -8
  23. data/sorbet-rails.gemspec +2 -2
  24. data/spec/bin/run_all_specs.sh +3 -4
  25. data/spec/bin/run_spec.sh +4 -1
  26. data/spec/generators/rails-template.rb +3 -20
  27. data/spec/generators/sorbet_test_cases.rb +17 -4
  28. data/spec/rails_helper.rb +5 -5
  29. data/spec/rake_rails_rbi_models_spec.rb +11 -4
  30. data/spec/sorbet_spec.rb +2 -1
  31. data/spec/support/v5.2/Gemfile +1 -3
  32. data/spec/support/v5.2/Gemfile.lock +66 -71
  33. data/spec/support/v5.2/app/controllers/application_controller.rb +1 -1
  34. data/spec/support/v5.2/app/mailers/application_mailer.rb +1 -1
  35. data/spec/support/v5.2/app/mailers/daily_prophet_mailer.rb +1 -1
  36. data/spec/support/v5.2/app/mailers/hogwarts_acceptance_mailer.rb +1 -1
  37. data/spec/support/v5.2/app/models/spell_book.rb +1 -1
  38. data/spec/support/v5.2/app/models/wand.rb +1 -1
  39. data/spec/support/v5.2/app/models/wizard.rb +1 -1
  40. data/spec/support/v5.2/config/environments/development.rb +1 -1
  41. data/spec/support/v5.2/config/environments/production.rb +1 -1
  42. data/spec/support/v5.2/config/environments/test.rb +1 -1
  43. data/spec/support/v5.2/config/routes.rb +1 -1
  44. data/spec/support/v5.2/sorbet_test_cases.rb +17 -4
  45. data/spec/support/v6.0/Gemfile +1 -1
  46. data/spec/support/v6.0/Gemfile.lock +81 -85
  47. data/spec/support/v6.0/app/mailers/application_mailer.rb +1 -1
  48. data/spec/support/v6.0/config/environments/development.rb +1 -1
  49. data/spec/support/v6.0/config/environments/test.rb +1 -1
  50. data/spec/support/v6.0/config/initializers/cookies_serializer.rb +1 -1
  51. data/spec/support/v6.0/config/initializers/sorbet_rails.rb +1 -1
  52. data/spec/support/v6.0/config/routes.rb +1 -1
  53. data/spec/support/v6.0/sorbet_test_cases.rb +17 -4
  54. data/spec/support/{v5.1 → v6.1}/.gitignore +13 -2
  55. data/spec/support/{v5.1 → v6.1}/Gemfile +12 -15
  56. data/spec/support/{v5.1 → v6.1}/Gemfile.lock +87 -59
  57. data/spec/support/{v5.0 → v6.1}/README.md +0 -0
  58. data/spec/support/{v5.0 → v6.1}/Rakefile +0 -0
  59. data/spec/support/{v5.0 → v6.1}/app/assets/config/manifest.js +0 -0
  60. data/spec/support/{v5.0 → v6.1}/app/assets/images/.keep +0 -0
  61. data/spec/support/{v5.1 → v6.1}/app/assets/stylesheets/application.css +0 -0
  62. data/spec/support/{v5.0 → v6.1}/app/controllers/application_controller.rb +1 -2
  63. data/spec/support/{v5.0 → v6.1}/app/controllers/concerns/.keep +0 -0
  64. data/spec/support/{v5.0 → v6.1}/app/helpers/application_helper.rb +0 -0
  65. data/spec/support/{v5.0 → v6.1}/app/helpers/bar_helper.rb +0 -0
  66. data/spec/support/{v5.0 → v6.1}/app/helpers/baz_helper.rb +0 -0
  67. data/spec/support/{v5.0 → v6.1}/app/helpers/foo_helper.rb +0 -0
  68. data/spec/support/v6.1/app/jobs/application_job.rb +8 -0
  69. data/spec/support/{v5.0 → v6.1}/app/jobs/award_house_point_hourglasses.rb +0 -0
  70. data/spec/support/{v5.1 → v6.1}/app/mailers/application_mailer.rb +1 -1
  71. data/spec/support/{v5.0 → v6.1}/app/mailers/daily_prophet_mailer.rb +0 -0
  72. data/spec/support/{v5.0 → v6.1}/app/mailers/hogwarts_acceptance_mailer.rb +0 -0
  73. data/spec/support/{v5.0 → v6.1}/app/models/application_record.rb +0 -0
  74. data/spec/support/{v5.0 → v6.1}/app/models/concerns/.keep +0 -0
  75. data/spec/support/{v5.0 → v6.1}/app/models/concerns/mythical.rb +0 -0
  76. data/spec/support/{v5.1 → v6.1}/app/models/headmaster.rb +1 -1
  77. data/spec/support/{v5.1 → v6.1}/app/models/potion.rb +0 -0
  78. data/spec/support/{v5.1 → v6.1}/app/models/robe.rb +0 -0
  79. data/spec/support/{v5.0 → v6.1}/app/models/school.rb +1 -1
  80. data/spec/support/{v5.1 → v6.1}/app/models/spell.rb +0 -0
  81. data/spec/support/{v5.0 → v6.1}/app/models/spell_book.rb +0 -0
  82. data/spec/support/{v5.0 → v6.1}/app/models/squib.rb +0 -0
  83. data/spec/support/{v5.1 → v6.1}/app/models/subject.rb +0 -0
  84. data/spec/support/{v5.0 → v6.1}/app/models/wand.rb +0 -0
  85. data/spec/support/{v5.0 → v6.1}/app/models/wizard.rb +2 -1
  86. data/spec/support/{v5.1 → v6.1}/app/views/layouts/application.html.erb +2 -1
  87. data/spec/support/{v5.0 → v6.1}/app/views/layouts/mailer.html.erb +0 -0
  88. data/spec/support/{v5.0 → v6.1}/app/views/layouts/mailer.text.erb +0 -0
  89. data/spec/support/v6.1/bin/bundle +114 -0
  90. data/spec/support/{v5.0 → v6.1}/bin/rails +0 -0
  91. data/spec/support/{v5.0 → v6.1}/bin/rake +0 -0
  92. data/spec/support/{v5.1 → v6.1}/bin/setup +6 -11
  93. data/spec/support/{v5.1 → v6.1}/config/application.rb +8 -4
  94. data/spec/support/{v5.0 → v6.1}/config/boot.rb +0 -0
  95. data/spec/support/{v5.1 → v6.1}/config/database.yml +1 -1
  96. data/spec/support/{v5.0 → v6.1}/config/environment.rb +0 -0
  97. data/spec/support/{v5.1 → v6.1}/config/environments/development.rb +12 -4
  98. data/spec/support/{v5.1 → v6.1}/config/environments/production.rb +29 -7
  99. data/spec/support/{v5.1 → v6.1}/config/environments/test.rb +13 -7
  100. data/spec/support/{v5.0 → v6.1}/config/initializers/application_controller_renderer.rb +0 -0
  101. data/spec/support/{v5.0 → v6.1}/config/initializers/backtrace_silencers.rb +0 -0
  102. data/spec/support/v6.1/config/initializers/content_security_policy.rb +29 -0
  103. data/spec/support/{v5.1 → v6.1}/config/initializers/cookies_serializer.rb +1 -1
  104. data/spec/support/{v5.0 → v6.1}/config/initializers/filter_parameter_logging.rb +0 -0
  105. data/spec/support/{v5.0 → v6.1}/config/initializers/inflections.rb +0 -0
  106. data/spec/support/{v5.0 → v6.1}/config/initializers/mime_types.rb +0 -0
  107. data/spec/support/{v5.0 → v6.1}/config/initializers/sorbet_rails.rb +1 -1
  108. data/spec/support/{v5.0 → v6.1}/config/initializers/wrap_parameters.rb +0 -0
  109. data/spec/support/{v5.1 → v6.1}/config/locales/en.yml +1 -1
  110. data/spec/support/{v5.1 → v6.1}/config/puma.rb +8 -26
  111. data/spec/support/v6.1/config/routes.rb +5 -0
  112. data/spec/support/v6.1/config/storage.yml +34 -0
  113. data/spec/support/{v5.0 → v6.1}/config.ru +0 -0
  114. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000001_create_wizards.rb +2 -2
  115. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000002_create_wands.rb +2 -2
  116. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000003_create_spell_books.rb +2 -2
  117. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000004_add_more_column_types_to_wands.rb +2 -2
  118. data/spec/support/v6.1/db/migrate/20190620000005_add_broom_to_wizard.rb +6 -0
  119. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000006_add_more_enums_to_wizard.rb +2 -2
  120. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000007_add_type_to_wizard.rb +2 -2
  121. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000008_add_robe_to_wizard.rb +2 -2
  122. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000009_add_school.rb +2 -2
  123. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000010_add_subject.rb +2 -2
  124. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000011_add_subjects_wizards.rb +2 -2
  125. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000012_add_spell.rb +2 -2
  126. data/spec/support/{v5.1 → v6.1}/db/migrate/20190620000013_add_spells_spell_books.rb +2 -2
  127. data/spec/support/{v5.0 → v6.1}/db/migrate/20190620000014_create_headmasters.rb +2 -2
  128. data/spec/support/{v5.0 → v6.1}/db/migrate/20190620000015_add_serialized_to_wizards.rb +2 -2
  129. data/spec/support/{v5.1 → v6.1}/db/schema.rb +14 -11
  130. data/spec/support/{v5.0 → v6.1}/db/seeds.rb +0 -0
  131. data/spec/support/{v5.0 → v6.1}/lib/assets/.keep +0 -0
  132. data/spec/support/{v5.0 → v6.1}/lib/mythical_rbi_plugin.rb +0 -0
  133. data/spec/support/{v5.0 → v6.1}/lib/tasks/.keep +0 -0
  134. data/spec/support/{v5.0 → v6.1}/log/.keep +0 -0
  135. data/spec/support/{v5.0 → v6.1}/sorbet_test_cases.rb +17 -4
  136. data/spec/support/{v5.0/tmp → v6.1/storage}/.keep +0 -0
  137. data/spec/support/{v5.0/vendor/assets/stylesheets → v6.1/tmp}/.keep +0 -0
  138. data/spec/support/{v5.1/app/assets/images → v6.1/tmp/pids}/.keep +0 -0
  139. data/spec/support/{v5.1/app/controllers/concerns → v6.1/vendor}/.keep +0 -0
  140. data/spec/test_data/v5.2/expected_active_record_base.rbi +10 -10
  141. data/spec/test_data/v5.2/expected_active_record_relation.rbi +10 -10
  142. data/spec/test_data/v5.2/expected_attachment.rbi +1 -1
  143. data/spec/test_data/v5.2/expected_blob.rbi +1 -1
  144. data/spec/test_data/v5.2/expected_headmaster.rbi +1 -1
  145. data/spec/test_data/v5.2/expected_internal_metadata.rbi +1 -1
  146. data/spec/test_data/v5.2/expected_potion.rbi +1 -1
  147. data/spec/test_data/v5.2/expected_robe.rbi +1 -1
  148. data/spec/test_data/v5.2/expected_routes.rbi +8 -0
  149. data/spec/test_data/v5.2/expected_schema_migration.rbi +1 -1
  150. data/spec/test_data/v5.2/expected_school.rbi +1 -1
  151. data/spec/test_data/v5.2/expected_spell/habtm_spell_books.rbi +1 -1
  152. data/spec/test_data/v5.2/expected_spell.rbi +1 -1
  153. data/spec/test_data/v5.2/expected_spell_book/habtm_spells.rbi +1 -1
  154. data/spec/test_data/v5.2/expected_spell_book.rbi +1 -1
  155. data/spec/test_data/v5.2/expected_squib.rbi +3 -3
  156. data/spec/test_data/v5.2/expected_subject/habtm_wizards.rbi +1 -1
  157. data/spec/test_data/v5.2/expected_subject.rbi +1 -1
  158. data/spec/test_data/v5.2/expected_wand.rbi +1 -1
  159. data/spec/test_data/v5.2/expected_wizard/habtm_subjects.rbi +1 -1
  160. data/spec/test_data/v5.2/expected_wizard.rbi +3 -3
  161. data/spec/test_data/v5.2/expected_wizard_wo_spellbook.rbi +3 -3
  162. data/spec/test_data/v6.0/expected_active_record_base.rbi +10 -10
  163. data/spec/test_data/v6.0/expected_active_record_relation.rbi +10 -10
  164. data/spec/test_data/v6.0/expected_attachment.rbi +1 -1
  165. data/spec/test_data/v6.0/expected_blob.rbi +1 -1
  166. data/spec/test_data/v6.0/expected_headmaster.rbi +1 -1
  167. data/spec/test_data/v6.0/expected_internal_metadata.rbi +1 -1
  168. data/spec/test_data/v6.0/expected_potion.rbi +1 -1
  169. data/spec/test_data/v6.0/expected_robe.rbi +1 -1
  170. data/spec/test_data/v6.0/expected_routes.rbi +8 -0
  171. data/spec/test_data/v6.0/expected_schema_migration.rbi +1 -1
  172. data/spec/test_data/v6.0/expected_school.rbi +1 -1
  173. data/spec/test_data/v6.0/expected_spell/habtm_spell_books.rbi +1 -1
  174. data/spec/test_data/v6.0/expected_spell.rbi +1 -1
  175. data/spec/test_data/v6.0/expected_spell_book/habtm_spells.rbi +1 -1
  176. data/spec/test_data/v6.0/expected_spell_book.rbi +1 -1
  177. data/spec/test_data/v6.0/expected_squib.rbi +3 -3
  178. data/spec/test_data/v6.0/expected_subject/habtm_wizards.rbi +1 -1
  179. data/spec/test_data/v6.0/expected_subject.rbi +1 -1
  180. data/spec/test_data/v6.0/expected_wand.rbi +1 -1
  181. data/spec/test_data/v6.0/expected_wizard/habtm_subjects.rbi +1 -1
  182. data/spec/test_data/v6.0/expected_wizard.rbi +3 -3
  183. data/spec/test_data/v6.0/expected_wizard_wo_spellbook.rbi +3 -3
  184. data/spec/test_data/{v5.1 → v6.1}/expected_active_record_base.rbi +16 -16
  185. data/spec/test_data/{v5.1 → v6.1}/expected_active_record_relation.rbi +26 -29
  186. data/spec/test_data/{v5.0 → v6.1}/expected_application_job.rbi +0 -0
  187. data/spec/test_data/{v5.0 → v6.1}/expected_application_mailer.rbi +0 -0
  188. data/spec/test_data/v6.1/expected_attachment.rbi +328 -0
  189. data/spec/test_data/{v5.0 → v6.1}/expected_award_house_point_hourglasses.rbi +0 -0
  190. data/spec/test_data/v6.1/expected_blob.rbi +376 -0
  191. data/spec/test_data/{v5.0 → v6.1}/expected_custom_application_job.rbi +0 -0
  192. data/spec/test_data/{v5.0 → v6.1}/expected_custom_application_mailer.rbi +0 -0
  193. data/spec/test_data/{v5.0 → v6.1}/expected_custom_award_house_point_hourglasses.rbi +0 -0
  194. data/spec/test_data/{v5.0 → v6.1}/expected_custom_daily_prophet_mailer.rbi +0 -0
  195. data/spec/test_data/{v5.0 → v6.1}/expected_custom_hogwarts_acceptance_mailer.rbi +0 -0
  196. data/spec/test_data/{v5.0 → v6.1}/expected_daily_prophet_mailer.rbi +0 -0
  197. data/spec/test_data/{v5.1 → v6.1}/expected_habtm_subjects.rbi +48 -0
  198. data/spec/test_data/{v5.1 → v6.1}/expected_habtm_wizards.rbi +48 -0
  199. data/spec/test_data/{v5.1 → v6.1}/expected_headmaster.rbi +25 -1
  200. data/spec/test_data/{v5.0 → v6.1}/expected_helpers.rbi +0 -0
  201. data/spec/test_data/{v5.0 → v6.1}/expected_helpers_with_application_and_devise_helpers.rbi +0 -0
  202. data/spec/test_data/{v5.0 → v6.1}/expected_hogwarts_acceptance_mailer.rbi +0 -0
  203. data/spec/test_data/{v5.1 → v6.1}/expected_internal_metadata.rbi +25 -1
  204. data/spec/test_data/{v5.0 → v6.1}/expected_no_routes.rbi +0 -0
  205. data/spec/test_data/{v5.1 → v6.1}/expected_potion.rbi +25 -1
  206. data/spec/test_data/v6.1/expected_record.rbi +289 -0
  207. data/spec/test_data/{v5.1 → v6.1}/expected_robe.rbi +25 -1
  208. data/spec/test_data/v6.1/expected_routes.rbi +175 -0
  209. data/spec/test_data/{v5.1 → v6.1}/expected_schema_migration.rbi +25 -1
  210. data/spec/test_data/{v5.1 → v6.1}/expected_school.rbi +25 -1
  211. data/spec/test_data/{v5.1 → v6.1}/expected_spell/habtm_spell_books.rbi +25 -1
  212. data/spec/test_data/{v5.1 → v6.1}/expected_spell.rbi +25 -1
  213. data/spec/test_data/{v5.1 → v6.1}/expected_spell_book/habtm_spell_books.rbi +48 -0
  214. data/spec/test_data/{v5.1 → v6.1}/expected_spell_book/habtm_spells.rbi +25 -1
  215. data/spec/test_data/{v5.1 → v6.1}/expected_spell_book.rbi +61 -1
  216. data/spec/test_data/{v5.1 → v6.1}/expected_squib.rbi +497 -59
  217. data/spec/test_data/{v5.0 → v6.1}/expected_srb_tc_output.txt +0 -0
  218. data/spec/test_data/{v5.1 → v6.1}/expected_subject/habtm_wizards.rbi +25 -1
  219. data/spec/test_data/{v5.1 → v6.1}/expected_subject.rbi +25 -1
  220. data/spec/test_data/v6.1/expected_variant_record.rbi +364 -0
  221. data/spec/test_data/{v5.1 → v6.1}/expected_wand.rbi +91 -1
  222. data/spec/test_data/{v5.1 → v6.1}/expected_wizard/habtm_subjects.rbi +25 -1
  223. data/spec/test_data/{v5.1 → v6.1}/expected_wizard.rbi +497 -59
  224. data/spec/test_data/{v5.1 → v6.1}/expected_wizard_wo_spellbook.rbi +491 -53
  225. metadata +266 -501
  226. data/.travis.yml +0 -42
  227. data/lib/sorbet-rails/type_assert/actionpack.rbi +0 -4
  228. data/spec/support/v5.0/.gitignore +0 -21
  229. data/spec/support/v5.0/Gemfile +0 -37
  230. data/spec/support/v5.0/Gemfile.lock +0 -161
  231. data/spec/support/v5.0/app/assets/stylesheets/application.css +0 -15
  232. data/spec/support/v5.0/app/jobs/application_job.rb +0 -3
  233. data/spec/support/v5.0/app/mailers/application_mailer.rb +0 -5
  234. data/spec/support/v5.0/app/models/headmaster.rb +0 -8
  235. data/spec/support/v5.0/app/models/potion.rb +0 -6
  236. data/spec/support/v5.0/app/models/robe.rb +0 -4
  237. data/spec/support/v5.0/app/models/spell.rb +0 -5
  238. data/spec/support/v5.0/app/models/subject.rb +0 -5
  239. data/spec/support/v5.0/app/views/layouts/application.html.erb +0 -13
  240. data/spec/support/v5.0/bin/bundle +0 -3
  241. data/spec/support/v5.0/bin/setup +0 -34
  242. data/spec/support/v5.0/bin/update +0 -29
  243. data/spec/support/v5.0/config/application.rb +0 -27
  244. data/spec/support/v5.0/config/database.yml +0 -25
  245. data/spec/support/v5.0/config/environments/development.rb +0 -48
  246. data/spec/support/v5.0/config/environments/production.rb +0 -75
  247. data/spec/support/v5.0/config/environments/test.rb +0 -43
  248. data/spec/support/v5.0/config/initializers/cookies_serializer.rb +0 -6
  249. data/spec/support/v5.0/config/initializers/new_framework_defaults.rb +0 -27
  250. data/spec/support/v5.0/config/initializers/session_store.rb +0 -4
  251. data/spec/support/v5.0/config/locales/en.yml +0 -23
  252. data/spec/support/v5.0/config/puma.rb +0 -48
  253. data/spec/support/v5.0/config/routes.rb +0 -5
  254. data/spec/support/v5.0/db/migrate/20190620000001_create_wizards.rb +0 -14
  255. data/spec/support/v5.0/db/migrate/20190620000002_create_wands.rb +0 -12
  256. data/spec/support/v5.0/db/migrate/20190620000003_create_spell_books.rb +0 -10
  257. data/spec/support/v5.0/db/migrate/20190620000004_add_more_column_types_to_wands.rb +0 -17
  258. data/spec/support/v5.0/db/migrate/20190620000005_add_broom_to_wizard.rb +0 -6
  259. data/spec/support/v5.0/db/migrate/20190620000006_add_more_enums_to_wizard.rb +0 -9
  260. data/spec/support/v5.0/db/migrate/20190620000007_add_type_to_wizard.rb +0 -6
  261. data/spec/support/v5.0/db/migrate/20190620000008_add_robe_to_wizard.rb +0 -8
  262. data/spec/support/v5.0/db/migrate/20190620000009_add_school.rb +0 -10
  263. data/spec/support/v5.0/db/migrate/20190620000010_add_subject.rb +0 -8
  264. data/spec/support/v5.0/db/migrate/20190620000011_add_subjects_wizards.rb +0 -8
  265. data/spec/support/v5.0/db/migrate/20190620000012_add_spell.rb +0 -8
  266. data/spec/support/v5.0/db/migrate/20190620000013_add_spells_spell_books.rb +0 -8
  267. data/spec/support/v5.0/db/schema.rb +0 -96
  268. data/spec/support/v5.0/public/robots.txt +0 -5
  269. data/spec/support/v5.1/README.md +0 -24
  270. data/spec/support/v5.1/Rakefile +0 -6
  271. data/spec/support/v5.1/app/assets/config/manifest.js +0 -2
  272. data/spec/support/v5.1/app/controllers/application_controller.rb +0 -4
  273. data/spec/support/v5.1/app/helpers/application_helper.rb +0 -3
  274. data/spec/support/v5.1/app/helpers/bar_helper.rb +0 -3
  275. data/spec/support/v5.1/app/helpers/baz_helper.rb +0 -3
  276. data/spec/support/v5.1/app/helpers/foo_helper.rb +0 -3
  277. data/spec/support/v5.1/app/jobs/application_job.rb +0 -3
  278. data/spec/support/v5.1/app/jobs/award_house_point_hourglasses.rb +0 -12
  279. data/spec/support/v5.1/app/mailers/daily_prophet_mailer.rb +0 -9
  280. data/spec/support/v5.1/app/mailers/hogwarts_acceptance_mailer.rb +0 -29
  281. data/spec/support/v5.1/app/models/application_record.rb +0 -4
  282. data/spec/support/v5.1/app/models/concerns/.keep +0 -0
  283. data/spec/support/v5.1/app/models/concerns/mythical.rb +0 -11
  284. data/spec/support/v5.1/app/models/school.rb +0 -5
  285. data/spec/support/v5.1/app/models/spell_book.rb +0 -18
  286. data/spec/support/v5.1/app/models/squib.rb +0 -6
  287. data/spec/support/v5.1/app/models/wand.rb +0 -19
  288. data/spec/support/v5.1/app/models/wizard.rb +0 -65
  289. data/spec/support/v5.1/app/views/layouts/mailer.html.erb +0 -13
  290. data/spec/support/v5.1/app/views/layouts/mailer.text.erb +0 -1
  291. data/spec/support/v5.1/bin/bundle +0 -3
  292. data/spec/support/v5.1/bin/rails +0 -4
  293. data/spec/support/v5.1/bin/rake +0 -4
  294. data/spec/support/v5.1/bin/update +0 -29
  295. data/spec/support/v5.1/bin/yarn +0 -11
  296. data/spec/support/v5.1/config/boot.rb +0 -4
  297. data/spec/support/v5.1/config/environment.rb +0 -6
  298. data/spec/support/v5.1/config/initializers/application_controller_renderer.rb +0 -9
  299. data/spec/support/v5.1/config/initializers/backtrace_silencers.rb +0 -8
  300. data/spec/support/v5.1/config/initializers/filter_parameter_logging.rb +0 -5
  301. data/spec/support/v5.1/config/initializers/inflections.rb +0 -17
  302. data/spec/support/v5.1/config/initializers/mime_types.rb +0 -5
  303. data/spec/support/v5.1/config/initializers/sorbet_rails.rb +0 -3
  304. data/spec/support/v5.1/config/initializers/wrap_parameters.rb +0 -15
  305. data/spec/support/v5.1/config/routes.rb +0 -5
  306. data/spec/support/v5.1/config.ru +0 -5
  307. data/spec/support/v5.1/db/migrate/20190620000005_add_broom_to_wizard.rb +0 -6
  308. data/spec/support/v5.1/db/migrate/20190620000014_create_headmasters.rb +0 -9
  309. data/spec/support/v5.1/db/migrate/20190620000015_add_serialized_to_wizards.rb +0 -9
  310. data/spec/support/v5.1/db/seeds.rb +0 -8
  311. data/spec/support/v5.1/lib/assets/.keep +0 -0
  312. data/spec/support/v5.1/lib/mythical_rbi_plugin.rb +0 -16
  313. data/spec/support/v5.1/lib/tasks/.keep +0 -0
  314. data/spec/support/v5.1/log/.keep +0 -0
  315. data/spec/support/v5.1/package.json +0 -5
  316. data/spec/support/v5.1/public/robots.txt +0 -1
  317. data/spec/support/v5.1/sorbet_test_cases.rb +0 -409
  318. data/spec/support/v5.1/tmp/.keep +0 -0
  319. data/spec/support/v5.1/vendor/.keep +0 -0
  320. data/spec/test_data/v5.0/expected_active_record_base.rbi +0 -113
  321. data/spec/test_data/v5.0/expected_active_record_relation.rbi +0 -198
  322. data/spec/test_data/v5.0/expected_habtm_subjects.rbi +0 -660
  323. data/spec/test_data/v5.0/expected_habtm_wizards.rbi +0 -660
  324. data/spec/test_data/v5.0/expected_headmaster.rbi +0 -328
  325. data/spec/test_data/v5.0/expected_internal_metadata.rbi +0 -298
  326. data/spec/test_data/v5.0/expected_potion.rbi +0 -280
  327. data/spec/test_data/v5.0/expected_robe.rbi +0 -301
  328. data/spec/test_data/v5.0/expected_routes.rbi +0 -27
  329. data/spec/test_data/v5.0/expected_schema_migration.rbi +0 -271
  330. data/spec/test_data/v5.0/expected_school.rbi +0 -301
  331. data/spec/test_data/v5.0/expected_spell/habtm_spell_books.rbi +0 -319
  332. data/spec/test_data/v5.0/expected_spell.rbi +0 -292
  333. data/spec/test_data/v5.0/expected_spell_book/habtm_spell_books.rbi +0 -637
  334. data/spec/test_data/v5.0/expected_spell_book/habtm_spells.rbi +0 -319
  335. data/spec/test_data/v5.0/expected_spell_book.rbi +0 -415
  336. data/spec/test_data/v5.0/expected_squib.rbi +0 -832
  337. data/spec/test_data/v5.0/expected_subject/habtm_wizards.rbi +0 -319
  338. data/spec/test_data/v5.0/expected_subject.rbi +0 -292
  339. data/spec/test_data/v5.0/expected_wand.rbi +0 -497
  340. data/spec/test_data/v5.0/expected_wizard/habtm_subjects.rbi +0 -319
  341. data/spec/test_data/v5.0/expected_wizard.rbi +0 -908
  342. data/spec/test_data/v5.0/expected_wizard_wo_spellbook.rbi +0 -902
  343. data/spec/test_data/v5.1/expected_application_job.rbi +0 -20
  344. data/spec/test_data/v5.1/expected_application_mailer.rbi +0 -5
  345. data/spec/test_data/v5.1/expected_award_house_point_hourglasses.rbi +0 -20
  346. data/spec/test_data/v5.1/expected_custom_application_job.rbi +0 -21
  347. data/spec/test_data/v5.1/expected_custom_application_mailer.rbi +0 -6
  348. data/spec/test_data/v5.1/expected_custom_award_house_point_hourglasses.rbi +0 -21
  349. data/spec/test_data/v5.1/expected_custom_daily_prophet_mailer.rbi +0 -8
  350. data/spec/test_data/v5.1/expected_custom_hogwarts_acceptance_mailer.rbi +0 -21
  351. data/spec/test_data/v5.1/expected_daily_prophet_mailer.rbi +0 -7
  352. data/spec/test_data/v5.1/expected_helpers.rbi +0 -27
  353. data/spec/test_data/v5.1/expected_helpers_with_application_and_devise_helpers.rbi +0 -34
  354. data/spec/test_data/v5.1/expected_hogwarts_acceptance_mailer.rbi +0 -20
  355. data/spec/test_data/v5.1/expected_no_routes.rbi +0 -4
  356. data/spec/test_data/v5.1/expected_routes.rbi +0 -27
  357. data/spec/test_data/v5.1/expected_srb_tc_output.txt +0 -1
@@ -11,48 +11,65 @@ PATH
11
11
  GEM
12
12
  remote: https://rubygems.org/
13
13
  specs:
14
- actioncable (5.1.7)
15
- actionpack (= 5.1.7)
14
+ actioncable (6.0.3.2)
15
+ actionpack (= 6.0.3.2)
16
16
  nio4r (~> 2.0)
17
- websocket-driver (~> 0.6.1)
18
- actionmailer (5.1.7)
19
- actionpack (= 5.1.7)
20
- actionview (= 5.1.7)
21
- activejob (= 5.1.7)
17
+ websocket-driver (>= 0.6.1)
18
+ actionmailbox (6.0.3.2)
19
+ actionpack (= 6.0.3.2)
20
+ activejob (= 6.0.3.2)
21
+ activerecord (= 6.0.3.2)
22
+ activestorage (= 6.0.3.2)
23
+ activesupport (= 6.0.3.2)
24
+ mail (>= 2.7.1)
25
+ actionmailer (6.0.3.2)
26
+ actionpack (= 6.0.3.2)
27
+ actionview (= 6.0.3.2)
28
+ activejob (= 6.0.3.2)
22
29
  mail (~> 2.5, >= 2.5.4)
23
30
  rails-dom-testing (~> 2.0)
24
- actionpack (5.1.7)
25
- actionview (= 5.1.7)
26
- activesupport (= 5.1.7)
27
- rack (~> 2.0)
31
+ actionpack (6.0.3.2)
32
+ actionview (= 6.0.3.2)
33
+ activesupport (= 6.0.3.2)
34
+ rack (~> 2.0, >= 2.0.8)
28
35
  rack-test (>= 0.6.3)
29
36
  rails-dom-testing (~> 2.0)
30
- rails-html-sanitizer (~> 1.0, >= 1.0.2)
31
- actionview (5.1.7)
32
- activesupport (= 5.1.7)
37
+ rails-html-sanitizer (~> 1.0, >= 1.2.0)
38
+ actiontext (6.0.3.2)
39
+ actionpack (= 6.0.3.2)
40
+ activerecord (= 6.0.3.2)
41
+ activestorage (= 6.0.3.2)
42
+ activesupport (= 6.0.3.2)
43
+ nokogiri (>= 1.8.5)
44
+ actionview (6.0.3.2)
45
+ activesupport (= 6.0.3.2)
33
46
  builder (~> 3.1)
34
47
  erubi (~> 1.4)
35
48
  rails-dom-testing (~> 2.0)
36
- rails-html-sanitizer (~> 1.0, >= 1.0.3)
37
- activejob (5.1.7)
38
- activesupport (= 5.1.7)
49
+ rails-html-sanitizer (~> 1.1, >= 1.2.0)
50
+ activejob (6.0.3.2)
51
+ activesupport (= 6.0.3.2)
39
52
  globalid (>= 0.3.6)
40
- activemodel (5.1.7)
41
- activesupport (= 5.1.7)
42
- activerecord (5.1.7)
43
- activemodel (= 5.1.7)
44
- activesupport (= 5.1.7)
45
- arel (~> 8.0)
46
- activesupport (5.1.7)
53
+ activemodel (6.0.3.2)
54
+ activesupport (= 6.0.3.2)
55
+ activerecord (6.0.3.2)
56
+ activemodel (= 6.0.3.2)
57
+ activesupport (= 6.0.3.2)
58
+ activestorage (6.0.3.2)
59
+ actionpack (= 6.0.3.2)
60
+ activejob (= 6.0.3.2)
61
+ activerecord (= 6.0.3.2)
62
+ marcel (~> 0.3.1)
63
+ activesupport (6.0.3.2)
47
64
  concurrent-ruby (~> 1.0, >= 1.0.2)
48
65
  i18n (>= 0.7, < 2)
49
66
  minitest (~> 5.1)
50
67
  tzinfo (~> 1.1)
51
- arel (8.0.0)
68
+ zeitwerk (~> 2.2, >= 2.2.2)
52
69
  ast (2.4.2)
53
70
  bindex (0.8.1)
54
71
  builder (3.2.4)
55
- byebug (11.1.1)
72
+ byebug (11.1.3)
56
73
  commander (4.6.0)
57
74
  highline (~> 2.0.0)
58
75
  concurrent-ruby (1.1.6)
@@ -61,19 +78,22 @@ GEM
61
78
  globalid (0.4.2)
62
79
  activesupport (>= 4.2.0)
63
80
  highline (2.0.3)
64
- i18n (1.8.2)
81
+ i18n (1.8.3)
65
82
  concurrent-ruby (~> 1.0)
66
83
  jbuilder (2.10.0)
67
84
  activesupport (>= 5.0.0)
68
- loofah (2.4.0)
85
+ loofah (2.6.0)
69
86
  crass (~> 1.0.2)
70
87
  nokogiri (>= 1.5.9)
71
88
  mail (2.7.1)
72
89
  mini_mime (>= 0.1.1)
90
+ marcel (0.3.3)
91
+ mimemagic (~> 0.3.2)
73
92
  method_source (1.0.0)
93
+ mimemagic (0.3.5)
74
94
  mini_mime (1.0.2)
75
95
  mini_portile2 (2.5.0)
76
- minitest (5.14.0)
96
+ minitest (5.14.1)
77
97
  nio4r (2.5.2)
78
98
  nokogiri (1.11.1)
79
99
  mini_portile2 (~> 2.5.0)
@@ -88,46 +108,50 @@ GEM
88
108
  parser (3.0.1.1)
89
109
  ast (~> 2.4.1)
90
110
  polyfill (1.9.0)
91
- puma (3.12.4)
111
+ puma (4.3.5)
112
+ nio4r (~> 2.0)
92
113
  racc (1.5.2)
93
114
  rack (2.2.3)
94
115
  rack-test (1.1.0)
95
116
  rack (>= 1.0, < 3)
96
- rails (5.1.7)
97
- actioncable (= 5.1.7)
98
- actionmailer (= 5.1.7)
99
- actionpack (= 5.1.7)
100
- actionview (= 5.1.7)
101
- activejob (= 5.1.7)
102
- activemodel (= 5.1.7)
103
- activerecord (= 5.1.7)
104
- activesupport (= 5.1.7)
117
+ rails (6.0.3.2)
118
+ actioncable (= 6.0.3.2)
119
+ actionmailbox (= 6.0.3.2)
120
+ actionmailer (= 6.0.3.2)
121
+ actionpack (= 6.0.3.2)
122
+ actiontext (= 6.0.3.2)
123
+ actionview (= 6.0.3.2)
124
+ activejob (= 6.0.3.2)
125
+ activemodel (= 6.0.3.2)
126
+ activerecord (= 6.0.3.2)
127
+ activestorage (= 6.0.3.2)
128
+ activesupport (= 6.0.3.2)
105
129
  bundler (>= 1.3.0)
106
- railties (= 5.1.7)
130
+ railties (= 6.0.3.2)
107
131
  sprockets-rails (>= 2.0.0)
108
132
  rails-dom-testing (2.0.3)
109
133
  activesupport (>= 4.2.0)
110
134
  nokogiri (>= 1.6)
111
135
  rails-html-sanitizer (1.3.0)
112
136
  loofah (~> 2.3)
113
- railties (5.1.7)
114
- actionpack (= 5.1.7)
115
- activesupport (= 5.1.7)
137
+ railties (6.0.3.2)
138
+ actionpack (= 6.0.3.2)
139
+ activesupport (= 6.0.3.2)
116
140
  method_source
117
141
  rake (>= 0.8.7)
118
- thor (>= 0.18.1, < 2.0)
142
+ thor (>= 0.20.3, < 2.0)
119
143
  rainbow (3.0.0)
120
144
  rake (13.0.1)
121
145
  safe_type (1.1.1)
122
- sorbet (0.5.5480)
123
- sorbet-static (= 0.5.5480)
146
+ sorbet (0.5.5815)
147
+ sorbet-static (= 0.5.5815)
124
148
  sorbet-coerce (0.4.0)
125
149
  polyfill (~> 1.8)
126
150
  safe_type (~> 1.1, >= 1.1.1)
127
151
  sorbet-runtime (>= 0.4.4704)
128
- sorbet-runtime (0.5.5480)
129
- sorbet-static (0.5.5480-universal-darwin-19)
130
- sprockets (4.0.0)
152
+ sorbet-runtime (0.5.5815)
153
+ sorbet-static (0.5.5815-universal-darwin-19)
154
+ sprockets (4.0.2)
131
155
  concurrent-ruby (~> 1.0)
132
156
  rack (> 1, < 3)
133
157
  sprockets-rails (3.2.1)
@@ -137,16 +161,17 @@ GEM
137
161
  sqlite3 (1.4.2)
138
162
  thor (1.0.1)
139
163
  thread_safe (0.3.6)
140
- tzinfo (1.2.6)
164
+ tzinfo (1.2.7)
141
165
  thread_safe (~> 0.1)
142
- web-console (3.7.0)
143
- actionview (>= 5.0)
144
- activemodel (>= 5.0)
166
+ web-console (4.0.4)
167
+ actionview (>= 6.0.0)
168
+ activemodel (>= 6.0.0)
145
169
  bindex (>= 0.4.0)
146
- railties (>= 5.0)
147
- websocket-driver (0.6.5)
170
+ railties (>= 6.0.0)
171
+ websocket-driver (0.7.3)
148
172
  websocket-extensions (>= 0.1.0)
149
173
  websocket-extensions (0.1.5)
174
+ zeitwerk (2.3.1)
150
175
 
151
176
  PLATFORMS
152
177
  ruby
@@ -154,15 +179,18 @@ PLATFORMS
154
179
 
155
180
  DEPENDENCIES
156
181
  byebug
157
- jbuilder (~> 2.5)
158
- puma (~> 3.7)
159
- rails (~> 5.1.7)
182
+ jbuilder (~> 2.7)
183
+ puma (~> 4.1)
184
+ rails (~> 6.0.3)
160
185
  sorbet
161
186
  sorbet-rails!
162
187
  sorbet-runtime
163
- sqlite3
188
+ sqlite3 (~> 1.4)
164
189
  tzinfo-data
165
190
  web-console (>= 3.3.0)
166
191
 
192
+ RUBY VERSION
193
+ ruby 2.5.5p157
194
+
167
195
  BUNDLED WITH
168
196
  2.2.0
File without changes
File without changes
File without changes
@@ -1,4 +1,3 @@
1
- # typed: strict
1
+ # typed: strong
2
2
  class ApplicationController < ActionController::Base
3
- protect_from_forgery with: :exception
4
3
  end
@@ -0,0 +1,8 @@
1
+ # typed: strong
2
+ class ApplicationJob < ActiveJob::Base
3
+ # Automatically retry jobs that encountered a deadlock
4
+ # retry_on ActiveRecord::Deadlocked
5
+
6
+ # Most jobs are safe to ignore if the underlying records are no longer available
7
+ # discard_on ActiveJob::DeserializationError
8
+ end
@@ -1,4 +1,4 @@
1
- # typed: strict
1
+ # typed: false
2
2
  class ApplicationMailer < ActionMailer::Base
3
3
  default from: 'from@example.com'
4
4
  layout 'mailer'
@@ -1,4 +1,4 @@
1
- # typed: strict
1
+ # typed: strong
2
2
  class Headmaster < ApplicationRecord
3
3
  belongs_to :school, required: false
4
4
  belongs_to :wizard, optional: true
File without changes
File without changes
@@ -1,4 +1,4 @@
1
- # typed: strict
1
+ # typed: strong
2
2
  class School < ApplicationRecord
3
3
  has_one :headmaster
4
4
  validates :headmaster, presence: true
File without changes
File without changes
File without changes
File without changes
@@ -61,5 +61,6 @@ class Wizard < ApplicationRecord
61
61
  belongs_to :school, optional: true
62
62
 
63
63
  scope :recent, -> { where('created_at > ?', 1.month.ago) }
64
-
64
+ has_one_attached :school_photo
65
+ has_many_attached :hats
65
66
  end
@@ -1,8 +1,9 @@
1
1
  <!DOCTYPE html>
2
2
  <html>
3
3
  <head>
4
- <title>V51</title>
4
+ <title>V60</title>
5
5
  <%= csrf_meta_tags %>
6
+ <%= csp_meta_tag %>
6
7
 
7
8
  <%= stylesheet_link_tag 'application', media: 'all' %>
8
9
  </head>
@@ -0,0 +1,114 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ #
5
+ # This file was generated by Bundler.
6
+ #
7
+ # The application 'bundle' is installed as part of a gem, and
8
+ # this file is here to facilitate running it.
9
+ #
10
+
11
+ require "rubygems"
12
+
13
+ m = Module.new do
14
+ module_function
15
+
16
+ def invoked_as_script?
17
+ File.expand_path($0) == File.expand_path(__FILE__)
18
+ end
19
+
20
+ def env_var_version
21
+ ENV["BUNDLER_VERSION"]
22
+ end
23
+
24
+ def cli_arg_version
25
+ return unless invoked_as_script? # don't want to hijack other binstubs
26
+ return unless "update".start_with?(ARGV.first || " ") # must be running `bundle update`
27
+ bundler_version = nil
28
+ update_index = nil
29
+ ARGV.each_with_index do |a, i|
30
+ if update_index && update_index.succ == i && a =~ Gem::Version::ANCHORED_VERSION_PATTERN
31
+ bundler_version = a
32
+ end
33
+ next unless a =~ /\A--bundler(?:[= ](#{Gem::Version::VERSION_PATTERN}))?\z/
34
+ bundler_version = $1
35
+ update_index = i
36
+ end
37
+ bundler_version
38
+ end
39
+
40
+ def gemfile
41
+ gemfile = ENV["BUNDLE_GEMFILE"]
42
+ return gemfile if gemfile && !gemfile.empty?
43
+
44
+ File.expand_path("../../Gemfile", __FILE__)
45
+ end
46
+
47
+ def lockfile
48
+ lockfile =
49
+ case File.basename(gemfile)
50
+ when "gems.rb" then gemfile.sub(/\.rb$/, gemfile)
51
+ else "#{gemfile}.lock"
52
+ end
53
+ File.expand_path(lockfile)
54
+ end
55
+
56
+ def lockfile_version
57
+ return unless File.file?(lockfile)
58
+ lockfile_contents = File.read(lockfile)
59
+ return unless lockfile_contents =~ /\n\nBUNDLED WITH\n\s{2,}(#{Gem::Version::VERSION_PATTERN})\n/
60
+ Regexp.last_match(1)
61
+ end
62
+
63
+ def bundler_version
64
+ @bundler_version ||=
65
+ env_var_version || cli_arg_version ||
66
+ lockfile_version
67
+ end
68
+
69
+ def bundler_requirement
70
+ return "#{Gem::Requirement.default}.a" unless bundler_version
71
+
72
+ bundler_gem_version = Gem::Version.new(bundler_version)
73
+
74
+ requirement = bundler_gem_version.approximate_recommendation
75
+
76
+ return requirement unless Gem::Version.new(Gem::VERSION) < Gem::Version.new("2.7.0")
77
+
78
+ requirement += ".a" if bundler_gem_version.prerelease?
79
+
80
+ requirement
81
+ end
82
+
83
+ def load_bundler!
84
+ ENV["BUNDLE_GEMFILE"] ||= gemfile
85
+
86
+ activate_bundler
87
+ end
88
+
89
+ def activate_bundler
90
+ gem_error = activation_error_handling do
91
+ gem "bundler", bundler_requirement
92
+ end
93
+ return if gem_error.nil?
94
+ require_error = activation_error_handling do
95
+ require "bundler/version"
96
+ end
97
+ return if require_error.nil? && Gem::Requirement.new(bundler_requirement).satisfied_by?(Gem::Version.new(Bundler::VERSION))
98
+ warn "Activating bundler (#{bundler_requirement}) failed:\n#{gem_error.message}\n\nTo install the version of bundler this project requires, run `gem install bundler -v '#{bundler_requirement}'`"
99
+ exit 42
100
+ end
101
+
102
+ def activation_error_handling
103
+ yield
104
+ nil
105
+ rescue StandardError, LoadError => e
106
+ e
107
+ end
108
+ end
109
+
110
+ m.load_bundler!
111
+
112
+ if m.invoked_as_script?
113
+ load Gem.bin_path("bundler", "bundle")
114
+ end
File without changes
File without changes
@@ -1,34 +1,29 @@
1
1
  #!/usr/bin/env ruby
2
- require 'pathname'
3
2
  require 'fileutils'
4
- include FileUtils
5
3
 
6
4
  # path to your application root.
7
- APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
5
+ APP_ROOT = File.expand_path('..', __dir__)
8
6
 
9
7
  def system!(*args)
10
8
  system(*args) || abort("\n== Command #{args} failed ==")
11
9
  end
12
10
 
13
- chdir APP_ROOT do
14
- # This script is a starting point to setup your application.
11
+ FileUtils.chdir APP_ROOT do
12
+ # This script is a way to setup or update your development environment automatically.
13
+ # This script is idempotent, so that you can run it at anytime and get an expectable outcome.
15
14
  # Add necessary setup steps to this file.
16
15
 
17
16
  puts '== Installing dependencies =='
18
17
  system! 'gem install bundler --conservative'
19
18
  system('bundle check') || system!('bundle install')
20
19
 
21
- # Install JavaScript dependencies if using Yarn
22
- # system('bin/yarn')
23
-
24
-
25
20
  # puts "\n== Copying sample files =="
26
21
  # unless File.exist?('config/database.yml')
27
- # cp 'config/database.yml.sample', 'config/database.yml'
22
+ # FileUtils.cp 'config/database.yml.sample', 'config/database.yml'
28
23
  # end
29
24
 
30
25
  puts "\n== Preparing database =="
31
- system! 'bin/rails db:setup'
26
+ system! 'bin/rails db:prepare'
32
27
 
33
28
  puts "\n== Removing old logs and tempfiles =="
34
29
  system! 'bin/rails log:clear tmp:clear'
@@ -6,8 +6,11 @@ require "rails"
6
6
  require "active_model/railtie"
7
7
  require "active_job/railtie"
8
8
  require "active_record/railtie"
9
+ require "active_storage/engine"
9
10
  require "action_controller/railtie"
10
11
  require "action_mailer/railtie"
12
+ require "action_mailbox/engine"
13
+ require "action_text/engine"
11
14
  require "action_view/railtie"
12
15
  # require "action_cable/engine"
13
16
  # require "sprockets/railtie"
@@ -17,14 +20,15 @@ require "action_view/railtie"
17
20
  # you've limited to :test, :development, or :production.
18
21
  Bundler.require(*Rails.groups)
19
22
 
20
- module V51
23
+ module V60
21
24
  class Application < Rails::Application
22
25
  # Initialize configuration defaults for originally generated Rails version.
23
- config.load_defaults 5.1
26
+ config.load_defaults 6.0
24
27
 
25
28
  # Settings in config/environments/* take precedence over those specified here.
26
- # Application configuration should go into files in config/initializers
27
- # -- all .rb files in that directory are automatically loaded.
29
+ # Application configuration can go into files in config/initializers
30
+ # -- all .rb files in that directory are automatically loaded after loading
31
+ # the framework and any gems in your application.
28
32
 
29
33
  # Don't generate system test files.
30
34
  config.generators.system_tests = nil
File without changes
@@ -1,4 +1,4 @@
1
- # SQLite version 3.x
1
+ # SQLite. Versions 3.8.0 and up are supported.
2
2
  # gem install sqlite3
3
3
  #
4
4
  # Ensure the SQLite 3 gem is defined in your Gemfile
File without changes
@@ -1,4 +1,4 @@
1
- # typed: false
1
+ # typed: strict
2
2
  Rails.application.configure do
3
3
  # Settings specified here will take precedence over those in config/application.rb.
4
4
 
@@ -14,12 +14,14 @@ Rails.application.configure do
14
14
  config.consider_all_requests_local = true
15
15
 
16
16
  # Enable/disable caching. By default caching is disabled.
17
- if Rails.root.join('tmp/caching-dev.txt').exist?
17
+ # Run rails dev:cache to toggle caching.
18
+ if Rails.root.join('tmp', 'caching-dev.txt').exist?
18
19
  config.action_controller.perform_caching = true
20
+ config.action_controller.enable_fragment_cache_logging = true
19
21
 
20
22
  config.cache_store = :memory_store
21
23
  config.public_file_server.headers = {
22
- 'Cache-Control' => "public, max-age=#{2.days.seconds.to_i}"
24
+ 'Cache-Control' => "public, max-age=#{2.days.to_i}"
23
25
  }
24
26
  else
25
27
  config.action_controller.perform_caching = false
@@ -27,6 +29,9 @@ Rails.application.configure do
27
29
  config.cache_store = :null_store
28
30
  end
29
31
 
32
+ # Store uploaded files on the local file system (see config/storage.yml for options).
33
+ config.active_storage.service = :local
34
+
30
35
  # Don't care if the mailer can't send.
31
36
  config.action_mailer.raise_delivery_errors = false
32
37
 
@@ -38,8 +43,11 @@ Rails.application.configure do
38
43
  # Raise an error on page load if there are pending migrations.
39
44
  config.active_record.migration_error = :page_load
40
45
 
46
+ # Highlight code that triggered database queries in logs.
47
+ config.active_record.verbose_query_logs = true
48
+
41
49
 
42
- # Raises error for missing translations
50
+ # Raises error for missing translations.
43
51
  # config.action_view.raise_on_missing_translations = true
44
52
 
45
53
  # Use an evented file watcher to asynchronously detect changes in source code,