cypress-on-rails 1.17.0 → 1.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (317) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ruby.yml +14 -14
  3. data/README.md +178 -22
  4. data/docs/authentication.md +30 -0
  5. data/docs/factory_bot_associations.md +14 -0
  6. data/lib/cypress_on_rails/configuration.rb +5 -0
  7. data/lib/cypress_on_rails/railtie.rb +10 -2
  8. data/lib/cypress_on_rails/vcr/insert_eject_middleware.rb +75 -0
  9. data/lib/cypress_on_rails/vcr/middleware_helpers.rb +51 -0
  10. data/lib/cypress_on_rails/vcr/use_cassette_middleware.rb +56 -0
  11. data/lib/cypress_on_rails/version.rb +1 -1
  12. data/lib/generators/cypress_on_rails/templates/config/initializers/cypress_on_rails.rb.erb +8 -0
  13. data/lib/generators/cypress_on_rails/templates/spec/cypress/support/commands.js +22 -0
  14. data/lib/generators/cypress_on_rails/templates/spec/cypress/support/on-rails.js +1 -0
  15. data/lib/generators/cypress_on_rails/templates/spec/e2e/e2e_helper.rb.erb +0 -5
  16. data/spec/cypress_on_rails/configuration_spec.rb +4 -1
  17. data/spec/cypress_on_rails/vcr/insert_eject_middleware_spec.rb +177 -0
  18. data/spec/cypress_on_rails/vcr/use_cassette_middleware_spec.rb +68 -0
  19. data/specs_e2e/rails_6_1/.gitattributes +10 -0
  20. data/specs_e2e/rails_6_1/Gemfile +20 -0
  21. data/specs_e2e/{rails_5_2 → rails_6_1}/Rakefile +1 -1
  22. data/specs_e2e/rails_6_1/app/assets/stylesheets/application.css +15 -0
  23. data/specs_e2e/rails_6_1/app/jobs/application_job.rb +7 -0
  24. data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/layouts/application.html.erb +1 -1
  25. data/specs_e2e/rails_6_1/bin/bundle +114 -0
  26. data/specs_e2e/rails_6_1/bin/rails +5 -0
  27. data/specs_e2e/rails_6_1/bin/rake +5 -0
  28. data/specs_e2e/{rails_5_2 → rails_6_1}/bin/setup +15 -4
  29. data/specs_e2e/rails_6_1/bin/spring +14 -0
  30. data/specs_e2e/rails_6_1/bin/yarn +17 -0
  31. data/specs_e2e/rails_6_1/config/application.rb +34 -0
  32. data/specs_e2e/rails_6_1/config/boot.rb +4 -0
  33. data/specs_e2e/rails_6_1/config/cable.yml +10 -0
  34. data/specs_e2e/rails_6_1/config/credentials.yml.enc +1 -0
  35. data/specs_e2e/{rails_5_2 → rails_6_1}/config/database.yml +7 -0
  36. data/specs_e2e/{rails_5_2 → rails_6_1}/config/environment.rb +1 -1
  37. data/specs_e2e/{rails_5_2 → rails_6_1}/config/environments/development.rb +22 -5
  38. data/specs_e2e/rails_6_1/config/environments/production.rb +120 -0
  39. data/specs_e2e/{rails_5_2 → rails_6_1}/config/environments/test.rb +24 -7
  40. data/specs_e2e/rails_6_1/config/initializers/backtrace_silencers.rb +8 -0
  41. data/specs_e2e/{rails_5_2 → rails_6_1}/config/initializers/content_security_policy.rb +5 -0
  42. data/specs_e2e/{rails_4_2 → rails_6_1}/config/initializers/filter_parameter_logging.rb +3 -1
  43. data/specs_e2e/rails_6_1/config/initializers/permissions_policy.rb +11 -0
  44. data/specs_e2e/{rails_3_2 → rails_6_1}/config/initializers/wrap_parameters.rb +5 -1
  45. data/specs_e2e/{rails_5_2 → rails_6_1}/config/locales/en.yml +1 -1
  46. data/specs_e2e/rails_6_1/config/master.key +1 -0
  47. data/specs_e2e/rails_6_1/config/puma.rb +43 -0
  48. data/specs_e2e/rails_6_1/config/storage.yml +34 -0
  49. data/specs_e2e/{rails_5_2 → rails_6_1}/config.ru +2 -1
  50. data/specs_e2e/{rails_5_2 → rails_6_1}/db/migrate/20180621085832_create_posts.rb +1 -1
  51. data/specs_e2e/rails_6_1/package.json +8 -0
  52. data/specs_e2e/rails_6_1/playwright-report/index.html +71 -0
  53. data/specs_e2e/rails_6_1/public/robots.txt +1 -0
  54. data/specs_e2e/rails_6_1/test-results/.last-run.json +4 -0
  55. data/specs_e2e/{rails_4_2 → rails_6_1}/test.sh +22 -15
  56. data/specs_e2e/rails_7_2/.gitattributes +9 -0
  57. data/specs_e2e/rails_7_2/.gitignore +16 -0
  58. data/specs_e2e/rails_7_2/.rubocop.yml +8 -0
  59. data/specs_e2e/rails_7_2/Gemfile +11 -0
  60. data/specs_e2e/{rails_4_2 → rails_7_2}/Rakefile +1 -1
  61. data/specs_e2e/rails_7_2/app/assets/stylesheets/application.css +15 -0
  62. data/specs_e2e/rails_7_2/app/controllers/application_controller.rb +4 -0
  63. data/specs_e2e/rails_7_2/app/controllers/posts_controller.rb +58 -0
  64. data/specs_e2e/rails_7_2/app/helpers/posts_helper.rb +2 -0
  65. data/specs_e2e/rails_7_2/app/jobs/application_job.rb +7 -0
  66. data/specs_e2e/rails_7_2/app/models/application_record.rb +3 -0
  67. data/specs_e2e/rails_7_2/app/models/post.rb +2 -0
  68. data/specs_e2e/rails_7_2/app/views/layouts/application.html.erb +22 -0
  69. data/specs_e2e/rails_7_2/app/views/posts/_form.html.erb +32 -0
  70. data/specs_e2e/rails_7_2/app/views/posts/edit.html.erb +6 -0
  71. data/specs_e2e/rails_7_2/app/views/posts/index.html.erb +31 -0
  72. data/specs_e2e/rails_7_2/app/views/posts/new.html.erb +5 -0
  73. data/specs_e2e/rails_7_2/app/views/posts/show.html.erb +19 -0
  74. data/specs_e2e/rails_7_2/bin/brakeman +7 -0
  75. data/specs_e2e/rails_7_2/bin/bundle +109 -0
  76. data/specs_e2e/rails_7_2/bin/importmap +4 -0
  77. data/specs_e2e/rails_7_2/bin/rails +4 -0
  78. data/specs_e2e/rails_7_2/bin/rake +4 -0
  79. data/specs_e2e/rails_7_2/bin/setup +37 -0
  80. data/specs_e2e/rails_7_2/config/application.rb +37 -0
  81. data/specs_e2e/rails_7_2/config/boot.rb +4 -0
  82. data/specs_e2e/rails_7_2/config/cable.yml +10 -0
  83. data/specs_e2e/rails_7_2/config/credentials.yml.enc +1 -0
  84. data/specs_e2e/rails_7_2/config/database.yml +32 -0
  85. data/specs_e2e/{rails_4_2 → rails_7_2}/config/environment.rb +1 -1
  86. data/specs_e2e/rails_7_2/config/environments/development.rb +54 -0
  87. data/specs_e2e/rails_7_2/config/environments/production.rb +105 -0
  88. data/specs_e2e/rails_7_2/config/environments/test.rb +45 -0
  89. data/specs_e2e/rails_7_2/config/importmap.rb +7 -0
  90. data/specs_e2e/rails_7_2/config/initializers/content_security_policy.rb +25 -0
  91. data/specs_e2e/rails_7_2/config/initializers/filter_parameter_logging.rb +8 -0
  92. data/specs_e2e/{rails_5_2 → rails_7_2}/config/initializers/inflections.rb +4 -4
  93. data/specs_e2e/rails_7_2/config/initializers/permissions_policy.rb +13 -0
  94. data/specs_e2e/rails_7_2/config/locales/en.yml +31 -0
  95. data/specs_e2e/rails_7_2/config/master.key +1 -0
  96. data/specs_e2e/rails_7_2/config/puma.rb +34 -0
  97. data/specs_e2e/rails_7_2/config/routes.rb +5 -0
  98. data/specs_e2e/rails_7_2/config/storage.yml +34 -0
  99. data/specs_e2e/{rails_4_2 → rails_7_2}/config.ru +3 -1
  100. data/specs_e2e/rails_7_2/db/migrate/20180621085832_create_posts.rb +11 -0
  101. data/specs_e2e/rails_7_2/db/seeds.rb +9 -0
  102. data/specs_e2e/rails_7_2/db/test.sqlite3-shm +0 -0
  103. data/specs_e2e/rails_7_2/db/test.sqlite3-wal +0 -0
  104. data/specs_e2e/rails_7_2/package.json +8 -0
  105. data/specs_e2e/rails_7_2/playwright-report/index.html +71 -0
  106. data/specs_e2e/{rails_4_2 → rails_7_2}/public/404.html +6 -6
  107. data/specs_e2e/rails_7_2/public/406-unsupported-browser.html +66 -0
  108. data/specs_e2e/{rails_4_2 → rails_7_2}/public/422.html +6 -6
  109. data/specs_e2e/{rails_4_2 → rails_7_2}/public/500.html +6 -6
  110. data/specs_e2e/rails_7_2/public/icon.png +0 -0
  111. data/specs_e2e/rails_7_2/public/icon.svg +3 -0
  112. data/specs_e2e/rails_7_2/public/robots.txt +1 -0
  113. data/specs_e2e/rails_7_2/storage/test.sqlite3 +0 -0
  114. data/specs_e2e/rails_7_2/test/controllers/posts_controller_test.rb +48 -0
  115. data/specs_e2e/rails_7_2/test/cypress_fixtures/posts.yml +11 -0
  116. data/specs_e2e/rails_7_2/test/fixtures/posts.yml +11 -0
  117. data/specs_e2e/rails_7_2/test/models/post_test.rb +7 -0
  118. data/specs_e2e/rails_7_2/test-results/.last-run.json +4 -0
  119. data/specs_e2e/rails_7_2/test.sh +57 -0
  120. data/specs_e2e/rails_8/.gitattributes +9 -0
  121. data/specs_e2e/rails_8/.gitignore +16 -0
  122. data/specs_e2e/rails_8/.rubocop.yml +8 -0
  123. data/specs_e2e/rails_8/Gemfile +20 -0
  124. data/specs_e2e/{rails_3_2 → rails_8}/Rakefile +2 -3
  125. data/specs_e2e/rails_8/app/assets/stylesheets/application.css +10 -0
  126. data/specs_e2e/rails_8/app/controllers/application_controller.rb +4 -0
  127. data/specs_e2e/rails_8/app/controllers/posts_controller.rb +58 -0
  128. data/specs_e2e/rails_8/app/helpers/posts_helper.rb +2 -0
  129. data/specs_e2e/rails_8/app/jobs/application_job.rb +7 -0
  130. data/specs_e2e/rails_8/app/models/application_record.rb +3 -0
  131. data/specs_e2e/rails_8/app/models/post.rb +2 -0
  132. data/specs_e2e/rails_8/app/views/layouts/application.html.erb +27 -0
  133. data/specs_e2e/rails_8/app/views/posts/_form.html.erb +32 -0
  134. data/specs_e2e/rails_8/app/views/posts/edit.html.erb +6 -0
  135. data/specs_e2e/rails_8/app/views/posts/index.html.erb +31 -0
  136. data/specs_e2e/rails_8/app/views/posts/new.html.erb +5 -0
  137. data/specs_e2e/rails_8/app/views/posts/show.html.erb +19 -0
  138. data/specs_e2e/rails_8/bin/brakeman +7 -0
  139. data/specs_e2e/rails_8/bin/bundle +109 -0
  140. data/specs_e2e/rails_8/bin/dev +2 -0
  141. data/specs_e2e/rails_8/bin/importmap +4 -0
  142. data/specs_e2e/rails_8/bin/rails +4 -0
  143. data/specs_e2e/rails_8/bin/rake +4 -0
  144. data/specs_e2e/rails_8/bin/setup +34 -0
  145. data/specs_e2e/rails_8/bin/thrust +5 -0
  146. data/specs_e2e/rails_8/config/application.rb +27 -0
  147. data/specs_e2e/rails_8/config/boot.rb +4 -0
  148. data/specs_e2e/rails_8/config/cable.yml +17 -0
  149. data/specs_e2e/rails_8/config/cache.yml +16 -0
  150. data/specs_e2e/rails_8/config/credentials.yml.enc +1 -0
  151. data/specs_e2e/rails_8/config/database.yml +41 -0
  152. data/specs_e2e/rails_8/config/deploy.yml +116 -0
  153. data/specs_e2e/rails_8/config/environment.rb +5 -0
  154. data/specs_e2e/rails_8/config/environments/development.rb +57 -0
  155. data/specs_e2e/rails_8/config/environments/production.rb +90 -0
  156. data/specs_e2e/rails_8/config/environments/test.rb +45 -0
  157. data/specs_e2e/rails_8/config/importmap.rb +7 -0
  158. data/specs_e2e/rails_8/config/initializers/content_security_policy.rb +25 -0
  159. data/specs_e2e/rails_8/config/initializers/filter_parameter_logging.rb +8 -0
  160. data/specs_e2e/rails_8/config/initializers/inflections.rb +16 -0
  161. data/specs_e2e/rails_8/config/locales/en.yml +31 -0
  162. data/specs_e2e/rails_8/config/master.key +1 -0
  163. data/specs_e2e/rails_8/config/puma.rb +41 -0
  164. data/specs_e2e/rails_8/config/queue.yml +18 -0
  165. data/specs_e2e/rails_8/config/recurring.yml +10 -0
  166. data/specs_e2e/rails_8/config/routes.rb +5 -0
  167. data/specs_e2e/rails_8/config/storage.yml +34 -0
  168. data/specs_e2e/rails_8/config.ru +6 -0
  169. data/specs_e2e/rails_8/db/cable_schema.rb +11 -0
  170. data/specs_e2e/rails_8/db/cache_schema.rb +14 -0
  171. data/specs_e2e/rails_8/db/migrate/20180621085832_create_posts.rb +11 -0
  172. data/specs_e2e/rails_8/db/queue_schema.rb +129 -0
  173. data/specs_e2e/rails_8/db/seeds.rb +9 -0
  174. data/specs_e2e/rails_8/package.json +8 -0
  175. data/specs_e2e/rails_8/playwright-report/index.html +71 -0
  176. data/specs_e2e/rails_8/public/400.html +114 -0
  177. data/specs_e2e/rails_8/public/404.html +114 -0
  178. data/specs_e2e/rails_8/public/406-unsupported-browser.html +114 -0
  179. data/specs_e2e/rails_8/public/422.html +114 -0
  180. data/specs_e2e/rails_8/public/500.html +114 -0
  181. data/specs_e2e/rails_8/public/icon.png +0 -0
  182. data/specs_e2e/rails_8/public/icon.svg +3 -0
  183. data/specs_e2e/rails_8/public/robots.txt +1 -0
  184. data/specs_e2e/rails_8/storage/test.sqlite3 +0 -0
  185. data/specs_e2e/rails_8/storage/test.sqlite3-shm +0 -0
  186. data/specs_e2e/rails_8/storage/test.sqlite3-wal +0 -0
  187. data/specs_e2e/rails_8/test/application_system_test_case.rb +5 -0
  188. data/specs_e2e/rails_8/test/controllers/posts_controller_test.rb +48 -0
  189. data/specs_e2e/rails_8/test/cypress_fixtures/posts.yml +11 -0
  190. data/specs_e2e/rails_8/test/fixtures/posts.yml +11 -0
  191. data/specs_e2e/rails_8/test/models/post_test.rb +7 -0
  192. data/specs_e2e/rails_8/test/test_helper.rb +15 -0
  193. data/specs_e2e/rails_8/test-results/.last-run.json +4 -0
  194. data/specs_e2e/{rails_5_2 → rails_8}/test.sh +1 -1
  195. metadata +217 -150
  196. data/lib/cypress_on_rails/vcr_middleware.rb +0 -73
  197. data/spec/cypress_on_rails/vcr_middleware_spec.rb +0 -119
  198. data/specs_e2e/rails_3_2/.gitignore +0 -9
  199. data/specs_e2e/rails_3_2/.ruby_version +0 -1
  200. data/specs_e2e/rails_3_2/Gemfile +0 -7
  201. data/specs_e2e/rails_3_2/README.rdoc +0 -261
  202. data/specs_e2e/rails_3_2/app/assets/stylesheets/application.css +0 -13
  203. data/specs_e2e/rails_3_2/app/controllers/application_controller.rb +0 -3
  204. data/specs_e2e/rails_3_2/app/controllers/welcome_controller.rb +0 -4
  205. data/specs_e2e/rails_3_2/app/helpers/application_helper.rb +0 -2
  206. data/specs_e2e/rails_3_2/app/models/post.rb +0 -21
  207. data/specs_e2e/rails_3_2/app/views/layouts/application.html.erb +0 -13
  208. data/specs_e2e/rails_3_2/app/views/welcome/index.html.erb +0 -24
  209. data/specs_e2e/rails_3_2/bin/rails +0 -6
  210. data/specs_e2e/rails_3_2/config/application.rb +0 -68
  211. data/specs_e2e/rails_3_2/config/boot.rb +0 -6
  212. data/specs_e2e/rails_3_2/config/environment.rb +0 -5
  213. data/specs_e2e/rails_3_2/config/environments/development.rb +0 -31
  214. data/specs_e2e/rails_3_2/config/environments/production.rb +0 -64
  215. data/specs_e2e/rails_3_2/config/environments/test.rb +0 -35
  216. data/specs_e2e/rails_3_2/config/initializers/backtrace_silencers.rb +0 -7
  217. data/specs_e2e/rails_3_2/config/initializers/inflections.rb +0 -15
  218. data/specs_e2e/rails_3_2/config/initializers/mime_types.rb +0 -5
  219. data/specs_e2e/rails_3_2/config/initializers/secret_token.rb +0 -7
  220. data/specs_e2e/rails_3_2/config/initializers/session_store.rb +0 -8
  221. data/specs_e2e/rails_3_2/config/locales/en.yml +0 -5
  222. data/specs_e2e/rails_3_2/config/routes.rb +0 -60
  223. data/specs_e2e/rails_3_2/config.ru +0 -4
  224. data/specs_e2e/rails_3_2/public/404.html +0 -26
  225. data/specs_e2e/rails_3_2/public/422.html +0 -26
  226. data/specs_e2e/rails_3_2/public/500.html +0 -25
  227. data/specs_e2e/rails_3_2/public/robots.txt +0 -5
  228. data/specs_e2e/rails_3_2/test.sh +0 -50
  229. data/specs_e2e/rails_4_2/.gitignore +0 -12
  230. data/specs_e2e/rails_4_2/Gemfile +0 -11
  231. data/specs_e2e/rails_4_2/README.rdoc +0 -28
  232. data/specs_e2e/rails_4_2/app/assets/javascripts/using_vcr.js +0 -2
  233. data/specs_e2e/rails_4_2/app/assets/stylesheets/using_vcr.css +0 -4
  234. data/specs_e2e/rails_4_2/app/controllers/application_controller.rb +0 -5
  235. data/specs_e2e/rails_4_2/app/controllers/using_vcr_controller.rb +0 -10
  236. data/specs_e2e/rails_4_2/app/controllers/welcome_controller.rb +0 -4
  237. data/specs_e2e/rails_4_2/app/models/post.rb +0 -23
  238. data/specs_e2e/rails_4_2/app/views/layouts/application.html.erb +0 -12
  239. data/specs_e2e/rails_4_2/app/views/using_vcr/index.html.erb +0 -6
  240. data/specs_e2e/rails_4_2/app/views/using_vcr/record_cats.html.erb +0 -7
  241. data/specs_e2e/rails_4_2/app/views/welcome/index.html.erb +0 -24
  242. data/specs_e2e/rails_4_2/bin/bundle +0 -3
  243. data/specs_e2e/rails_4_2/bin/rails +0 -4
  244. data/specs_e2e/rails_4_2/bin/rake +0 -4
  245. data/specs_e2e/rails_4_2/bin/setup +0 -29
  246. data/specs_e2e/rails_4_2/config/application.rb +0 -32
  247. data/specs_e2e/rails_4_2/config/boot.rb +0 -3
  248. data/specs_e2e/rails_4_2/config/environments/development.rb +0 -25
  249. data/specs_e2e/rails_4_2/config/environments/production.rb +0 -64
  250. data/specs_e2e/rails_4_2/config/environments/test.rb +0 -42
  251. data/specs_e2e/rails_4_2/config/initializers/backtrace_silencers.rb +0 -7
  252. data/specs_e2e/rails_4_2/config/initializers/cookies_serializer.rb +0 -3
  253. data/specs_e2e/rails_4_2/config/initializers/session_store.rb +0 -3
  254. data/specs_e2e/rails_4_2/config/initializers/to_time_preserves_timezone.rb +0 -10
  255. data/specs_e2e/rails_4_2/config/initializers/wrap_parameters.rb +0 -9
  256. data/specs_e2e/rails_4_2/config/locales/en.yml +0 -23
  257. data/specs_e2e/rails_4_2/config/routes.rb +0 -61
  258. data/specs_e2e/rails_4_2/config/secrets.yml +0 -22
  259. data/specs_e2e/rails_4_2/package.json +0 -12
  260. data/specs_e2e/rails_4_2/playwright-report/index.html +0 -62
  261. data/specs_e2e/rails_4_2/public/favicon.ico +0 -0
  262. data/specs_e2e/rails_4_2/public/robots.txt +0 -5
  263. data/specs_e2e/rails_4_2/spec/fixtures/vcr_cassettes/cats.yml +0 -63
  264. data/specs_e2e/rails_5_2/Gemfile +0 -15
  265. data/specs_e2e/rails_5_2/app/assets/javascripts/posts.js +0 -2
  266. data/specs_e2e/rails_5_2/app/assets/stylesheets/posts.css +0 -4
  267. data/specs_e2e/rails_5_2/app/assets/stylesheets/scaffold.css +0 -80
  268. data/specs_e2e/rails_5_2/app/jobs/application_job.rb +0 -2
  269. data/specs_e2e/rails_5_2/app/views/welcome/index.html.erb +0 -5
  270. data/specs_e2e/rails_5_2/bin/bundle +0 -3
  271. data/specs_e2e/rails_5_2/bin/rails +0 -4
  272. data/specs_e2e/rails_5_2/bin/rake +0 -4
  273. data/specs_e2e/rails_5_2/bin/update +0 -25
  274. data/specs_e2e/rails_5_2/config/application.rb +0 -33
  275. data/specs_e2e/rails_5_2/config/boot.rb +0 -4
  276. data/specs_e2e/rails_5_2/config/credentials.yml.enc +0 -1
  277. data/specs_e2e/rails_5_2/config/environments/production.rb +0 -68
  278. data/specs_e2e/rails_5_2/config/initializers/backtrace_silencers.rb +0 -7
  279. data/specs_e2e/rails_5_2/config/initializers/filter_parameter_logging.rb +0 -4
  280. data/specs_e2e/rails_5_2/config/initializers/mime_types.rb +0 -4
  281. data/specs_e2e/rails_5_2/config/initializers/wrap_parameters.rb +0 -9
  282. data/specs_e2e/rails_5_2/config/master.key +0 -1
  283. data/specs_e2e/rails_5_2/public/favicon.ico +0 -0
  284. data/specs_e2e/rails_5_2/public/robots.txt +0 -1
  285. /data/specs_e2e/{rails_5_2 → rails_6_1}/.gitignore +0 -0
  286. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/controllers/application_controller.rb +0 -0
  287. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/controllers/posts_controller.rb +0 -0
  288. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/helpers/posts_helper.rb +0 -0
  289. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/models/application_record.rb +0 -0
  290. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/models/post.rb +0 -0
  291. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/_form.html.erb +0 -0
  292. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/edit.html.erb +0 -0
  293. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/index.html.erb +0 -0
  294. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/new.html.erb +0 -0
  295. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/show.html.erb +0 -0
  296. /data/specs_e2e/{rails_5_2 → rails_6_1}/config/initializers/application_controller_renderer.rb +0 -0
  297. /data/specs_e2e/{rails_5_2 → rails_6_1}/config/initializers/cookies_serializer.rb +0 -0
  298. /data/specs_e2e/{rails_4_2 → rails_6_1}/config/initializers/inflections.rb +0 -0
  299. /data/specs_e2e/{rails_4_2 → rails_6_1}/config/initializers/mime_types.rb +0 -0
  300. /data/specs_e2e/{rails_5_2 → rails_6_1}/config/routes.rb +0 -0
  301. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/404.html +0 -0
  302. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/422.html +0 -0
  303. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/500.html +0 -0
  304. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/apple-touch-icon-precomposed.png +0 -0
  305. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/apple-touch-icon.png +0 -0
  306. /data/specs_e2e/{rails_3_2 → rails_6_1}/public/favicon.ico +0 -0
  307. /data/specs_e2e/{rails_5_2 → rails_6_1}/test/controllers/posts_controller_test.rb +0 -0
  308. /data/specs_e2e/{rails_5_2 → rails_6_1}/test/cypress_fixtures/posts.yml +0 -0
  309. /data/specs_e2e/{rails_5_2 → rails_6_1}/test/fixtures/posts.yml +0 -0
  310. /data/specs_e2e/{rails_5_2 → rails_6_1}/test/models/post_test.rb +0 -0
  311. /data/specs_e2e/{rails_3_2/log → rails_6_1/vendor}/.keep +0 -0
  312. /data/specs_e2e/{rails_3_2/tmp → rails_7_2/vendor}/.keep +0 -0
  313. /data/specs_e2e/{rails_4_2/spec → rails_7_2/vendor/javascript}/.keep +0 -0
  314. /data/specs_e2e/{rails_5_2 → rails_8}/README.md +0 -0
  315. /data/specs_e2e/{rails_4_2/vendor → rails_8/storage}/.keep +0 -0
  316. /data/specs_e2e/{rails_5_2 → rails_8}/vendor/.keep +0 -0
  317. /data/specs_e2e/{rails_3_2/vendor/.gitkeep → rails_8/vendor/javascript/.keep} +0 -0
@@ -0,0 +1,54 @@
1
+ require "active_support/core_ext/integer/time"
2
+
3
+ Rails.application.configure do
4
+ # Settings specified here will take precedence over those in config/application.rb.
5
+
6
+ # In the development environment your application's code is reloaded any time
7
+ # it changes. This slows down response time but is perfect for development
8
+ # since you don't have to restart the web server when you make code changes.
9
+ config.enable_reloading = true
10
+
11
+ # Do not eager load code on boot.
12
+ config.eager_load = false
13
+
14
+ # Show full error reports.
15
+ config.consider_all_requests_local = true
16
+
17
+ # Enable server timing.
18
+ config.server_timing = true
19
+
20
+ # Enable/disable caching. By default caching is disabled.
21
+ # Run rails dev:cache to toggle caching.
22
+ if Rails.root.join("tmp/caching-dev.txt").exist?
23
+ config.action_controller.perform_caching = true
24
+ config.action_controller.enable_fragment_cache_logging = true
25
+
26
+ config.cache_store = :memory_store
27
+ config.public_file_server.headers = { "Cache-Control" => "public, max-age=#{2.days.to_i}" }
28
+ else
29
+ config.action_controller.perform_caching = false
30
+
31
+ config.cache_store = :null_store
32
+ end
33
+
34
+ # Store uploaded files on the local file system (see config/storage.yml for options).
35
+ config.active_storage.service = :local
36
+
37
+ # Print deprecation notices to the Rails logger.
38
+ config.active_support.deprecation = :log
39
+
40
+ # Raise exceptions for disallowed deprecations.
41
+ config.active_support.disallowed_deprecation = :raise
42
+
43
+ # Tell Active Support which deprecation messages to disallow.
44
+ config.active_support.disallowed_deprecation_warnings = []
45
+
46
+ # Raise an error on page load if there are pending migrations.
47
+ config.active_record.migration_error = :page_load
48
+
49
+ # Highlight code that triggered database queries in logs.
50
+ config.active_record.verbose_query_logs = true
51
+
52
+ # Highlight code that enqueued background job in logs.
53
+ config.active_job.verbose_enqueue_logs = true
54
+ end
@@ -0,0 +1,105 @@
1
+ require "active_support/core_ext/integer/time"
2
+
3
+ Rails.application.configure do
4
+ # Settings specified here will take precedence over those in config/application.rb.
5
+
6
+ # Code is not reloaded between requests.
7
+ config.enable_reloading = false
8
+
9
+ # Eager load code on boot. This eager loads most of Rails and
10
+ # your application in memory, allowing both threaded web servers
11
+ # and those relying on copy on write to perform better.
12
+ # Rake tasks automatically ignore this option for performance.
13
+ config.eager_load = true
14
+
15
+ # Full error reports are disabled and caching is turned on.
16
+ config.consider_all_requests_local = false
17
+ config.action_controller.perform_caching = true
18
+
19
+ # Ensures that a master key has been made available in ENV["RAILS_MASTER_KEY"], config/master.key, or an environment
20
+ # key such as config/credentials/production.key. This key is used to decrypt credentials (and other encrypted files).
21
+ # config.require_master_key = true
22
+
23
+ # Disable serving static files from `public/`, relying on NGINX/Apache to do so instead.
24
+ # config.public_file_server.enabled = false
25
+
26
+ # Compress CSS using a preprocessor.
27
+ # config.assets.css_compressor = :sass
28
+
29
+ # Do not fall back to assets pipeline if a precompiled asset is missed.
30
+ config.assets.compile = false
31
+
32
+ # Enable serving of images, stylesheets, and JavaScripts from an asset server.
33
+ # config.asset_host = "http://assets.example.com"
34
+
35
+ # Specifies the header that your server uses for sending files.
36
+ # config.action_dispatch.x_sendfile_header = "X-Sendfile" # for Apache
37
+ # config.action_dispatch.x_sendfile_header = "X-Accel-Redirect" # for NGINX
38
+
39
+ # Store uploaded files on the local file system (see config/storage.yml for options).
40
+ config.active_storage.service = :local
41
+
42
+ # Mount Action Cable outside main process or domain.
43
+ # config.action_cable.mount_path = nil
44
+ # config.action_cable.url = "wss://example.com/cable"
45
+ # config.action_cable.allowed_request_origins = [ "http://example.com", /http:\/\/example.*/ ]
46
+
47
+ # Assume all access to the app is happening through a SSL-terminating reverse proxy.
48
+ # Can be used together with config.force_ssl for Strict-Transport-Security and secure cookies.
49
+ # config.assume_ssl = true
50
+
51
+ # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
52
+ config.force_ssl = true
53
+
54
+ # Skip http-to-https redirect for the default health check endpoint.
55
+ # config.ssl_options = { redirect: { exclude: ->(request) { request.path == "/up" } } }
56
+
57
+ # Log to STDOUT by default
58
+ config.logger = ActiveSupport::Logger.new(STDOUT)
59
+ .tap { |logger| logger.formatter = ::Logger::Formatter.new }
60
+ .then { |logger| ActiveSupport::TaggedLogging.new(logger) }
61
+
62
+ # Prepend all log lines with the following tags.
63
+ config.log_tags = [ :request_id ]
64
+
65
+ # "info" includes generic and useful information about system operation, but avoids logging too much
66
+ # information to avoid inadvertent exposure of personally identifiable information (PII). If you
67
+ # want to log everything, set the level to "debug".
68
+ config.log_level = ENV.fetch("RAILS_LOG_LEVEL", "info")
69
+
70
+ # Use a different cache store in production.
71
+ # config.cache_store = :mem_cache_store
72
+
73
+ # Use a real queuing backend for Active Job (and separate queues per environment).
74
+ # config.active_job.queue_adapter = :resque
75
+ # config.active_job.queue_name_prefix = "app_production"
76
+
77
+ # Disable caching for Action Mailer templates even if Action Controller
78
+ # caching is enabled.
79
+ config.action_mailer.perform_caching = false
80
+
81
+ # Ignore bad email addresses and do not raise email delivery errors.
82
+ # Set this to true and configure the email server for immediate delivery to raise delivery errors.
83
+ # config.action_mailer.raise_delivery_errors = false
84
+
85
+ # Enable locale fallbacks for I18n (makes lookups for any locale fall back to
86
+ # the I18n.default_locale when a translation cannot be found).
87
+ config.i18n.fallbacks = true
88
+
89
+ # Don't log any deprecations.
90
+ config.active_support.report_deprecations = false
91
+
92
+ # Do not dump schema after migrations.
93
+ config.active_record.dump_schema_after_migration = false
94
+
95
+ # Only use :id for inspections in production.
96
+ config.active_record.attributes_for_inspect = [ :id ]
97
+
98
+ # Enable DNS rebinding protection and other `Host` header attacks.
99
+ # config.hosts = [
100
+ # "example.com", # Allow requests from example.com
101
+ # /.*\.example\.com/ # Allow requests from subdomains like `www.example.com`
102
+ # ]
103
+ # Skip DNS rebinding protection for the default health check endpoint.
104
+ # config.host_authorization = { exclude: ->(request) { request.path == "/up" } }
105
+ end
@@ -0,0 +1,45 @@
1
+ require "active_support/core_ext/integer/time"
2
+
3
+ # The test environment is used exclusively to run your application's
4
+ # test suite. You never need to work with it otherwise. Remember that
5
+ # your test database is "scratch space" for the test suite and is wiped
6
+ # and recreated between test runs. Don't rely on the data there!
7
+
8
+ Rails.application.configure do
9
+ # Settings specified here will take precedence over those in config/application.rb.
10
+
11
+ # While tests run files are not watched, reloading is not necessary.
12
+ config.enable_reloading = false
13
+
14
+ # Eager loading loads your entire application. When running a single test locally,
15
+ # this is usually not necessary, and can slow down your test suite. However, it's
16
+ # recommended that you enable it in continuous integration systems to ensure eager
17
+ # loading is working properly before deploying your code.
18
+ config.eager_load = ENV["CI"].present?
19
+
20
+ # Configure public file server for tests with Cache-Control for performance.
21
+ config.public_file_server.headers = { "Cache-Control" => "public, max-age=#{1.hour.to_i}" }
22
+
23
+ # Show full error reports and disable caching.
24
+ config.consider_all_requests_local = true
25
+ config.action_controller.perform_caching = false
26
+ config.cache_store = :null_store
27
+
28
+ # Render exception templates for rescuable exceptions and raise for other exceptions.
29
+ config.action_dispatch.show_exceptions = :rescuable
30
+
31
+ # Disable request forgery protection in test environment.
32
+ config.action_controller.allow_forgery_protection = false
33
+
34
+ # Store uploaded files on the local file system in a temporary directory.
35
+ config.active_storage.service = :test
36
+
37
+ # Print deprecation notices to the stderr.
38
+ config.active_support.deprecation = :stderr
39
+
40
+ # Raise exceptions for disallowed deprecations.
41
+ config.active_support.disallowed_deprecation = :raise
42
+
43
+ # Tell Active Support which deprecation messages to disallow.
44
+ config.active_support.disallowed_deprecation_warnings = []
45
+ end
@@ -0,0 +1,7 @@
1
+ # Pin npm packages by running ./bin/importmap
2
+
3
+ pin "application"
4
+ pin "@hotwired/turbo-rails", to: "turbo.min.js"
5
+ pin "@hotwired/stimulus", to: "stimulus.min.js"
6
+ pin "@hotwired/stimulus-loading", to: "stimulus-loading.js"
7
+ pin_all_from "app/javascript/controllers", under: "controllers"
@@ -0,0 +1,25 @@
1
+ # Be sure to restart your server when you modify this file.
2
+
3
+ # Define an application-wide content security policy.
4
+ # See the Securing Rails Applications Guide for more information:
5
+ # https://guides.rubyonrails.org/security.html#content-security-policy-header
6
+
7
+ # Rails.application.configure do
8
+ # config.content_security_policy do |policy|
9
+ # policy.default_src :self, :https
10
+ # policy.font_src :self, :https, :data
11
+ # policy.img_src :self, :https, :data
12
+ # policy.object_src :none
13
+ # policy.script_src :self, :https
14
+ # policy.style_src :self, :https
15
+ # # Specify URI for violation reports
16
+ # # policy.report_uri "/csp-violation-report-endpoint"
17
+ # end
18
+ #
19
+ # # Generate session nonces for permitted importmap, inline scripts, and inline styles.
20
+ # config.content_security_policy_nonce_generator = ->(request) { request.session.id.to_s }
21
+ # config.content_security_policy_nonce_directives = %w(script-src style-src)
22
+ #
23
+ # # Report violations without enforcing the policy.
24
+ # # config.content_security_policy_report_only = true
25
+ # end
@@ -0,0 +1,8 @@
1
+ # Be sure to restart your server when you modify this file.
2
+
3
+ # Configure parameters to be partially matched (e.g. passw matches password) and filtered from the log file.
4
+ # Use this to limit dissemination of sensitive information.
5
+ # See the ActiveSupport::ParameterFilter documentation for supported notations and behaviors.
6
+ Rails.application.config.filter_parameters += [
7
+ :passw, :email, :secret, :token, :_key, :crypt, :salt, :certificate, :otp, :ssn
8
+ ]
@@ -4,13 +4,13 @@
4
4
  # are locale specific, and you may define rules for as many different
5
5
  # locales as you wish. All of these examples are active by default:
6
6
  # ActiveSupport::Inflector.inflections(:en) do |inflect|
7
- # inflect.plural /^(ox)$/i, '\1en'
8
- # inflect.singular /^(ox)en/i, '\1'
9
- # inflect.irregular 'person', 'people'
7
+ # inflect.plural /^(ox)$/i, "\\1en"
8
+ # inflect.singular /^(ox)en/i, "\\1"
9
+ # inflect.irregular "person", "people"
10
10
  # inflect.uncountable %w( fish sheep )
11
11
  # end
12
12
 
13
13
  # These inflection rules are supported but not enabled by default:
14
14
  # ActiveSupport::Inflector.inflections(:en) do |inflect|
15
- # inflect.acronym 'RESTful'
15
+ # inflect.acronym "RESTful"
16
16
  # end
@@ -0,0 +1,13 @@
1
+ # Be sure to restart your server when you modify this file.
2
+
3
+ # Define an application-wide HTTP permissions policy. For further
4
+ # information see: https://developers.google.com/web/updates/2018/06/feature-policy
5
+
6
+ # Rails.application.config.permissions_policy do |policy|
7
+ # policy.camera :none
8
+ # policy.gyroscope :none
9
+ # policy.microphone :none
10
+ # policy.usb :none
11
+ # policy.fullscreen :self
12
+ # policy.payment :self, "https://secure.example.com"
13
+ # end
@@ -0,0 +1,31 @@
1
+ # Files in the config/locales directory are used for internationalization and
2
+ # are automatically loaded by Rails. If you want to use locales other than
3
+ # English, add the necessary files in this directory.
4
+ #
5
+ # To use the locales, use `I18n.t`:
6
+ #
7
+ # I18n.t "hello"
8
+ #
9
+ # In views, this is aliased to just `t`:
10
+ #
11
+ # <%= t("hello") %>
12
+ #
13
+ # To use a different locale, set it with `I18n.locale`:
14
+ #
15
+ # I18n.locale = :es
16
+ #
17
+ # This would use the information in config/locales/es.yml.
18
+ #
19
+ # To learn more about the API, please read the Rails Internationalization guide
20
+ # at https://guides.rubyonrails.org/i18n.html.
21
+ #
22
+ # Be aware that YAML interprets the following case-insensitive strings as
23
+ # booleans: `true`, `false`, `on`, `off`, `yes`, `no`. Therefore, these strings
24
+ # must be quoted to be interpreted as strings. For example:
25
+ #
26
+ # en:
27
+ # "yes": yup
28
+ # enabled: "ON"
29
+
30
+ en:
31
+ hello: "Hello world"
@@ -0,0 +1 @@
1
+ 5b6ca964fe3f4c95d39f82330b15718d
@@ -0,0 +1,34 @@
1
+ # This configuration file will be evaluated by Puma. The top-level methods that
2
+ # are invoked here are part of Puma's configuration DSL. For more information
3
+ # about methods provided by the DSL, see https://puma.io/puma/Puma/DSL.html.
4
+
5
+ # Puma starts a configurable number of processes (workers) and each process
6
+ # serves each request in a thread from an internal thread pool.
7
+ #
8
+ # The ideal number of threads per worker depends both on how much time the
9
+ # application spends waiting for IO operations and on how much you wish to
10
+ # to prioritize throughput over latency.
11
+ #
12
+ # As a rule of thumb, increasing the number of threads will increase how much
13
+ # traffic a given process can handle (throughput), but due to CRuby's
14
+ # Global VM Lock (GVL) it has diminishing returns and will degrade the
15
+ # response time (latency) of the application.
16
+ #
17
+ # The default is set to 3 threads as it's deemed a decent compromise between
18
+ # throughput and latency for the average Rails application.
19
+ #
20
+ # Any libraries that use a connection pool or another resource pool should
21
+ # be configured to provide at least as many connections as the number of
22
+ # threads. This includes Active Record's `pool` parameter in `database.yml`.
23
+ threads_count = ENV.fetch("RAILS_MAX_THREADS", 3)
24
+ threads threads_count, threads_count
25
+
26
+ # Specifies the `port` that Puma will listen on to receive requests; default is 3000.
27
+ port ENV.fetch("PORT", 3000)
28
+
29
+ # Allow puma to be restarted by `bin/rails restart` command.
30
+ plugin :tmp_restart
31
+
32
+ # Specify the PID file. Defaults to tmp/pids/server.pid in development.
33
+ # In other environments, only set the PID file if requested.
34
+ pidfile ENV["PIDFILE"] if ENV["PIDFILE"]
@@ -0,0 +1,5 @@
1
+ Rails.application.routes.draw do
2
+ resources :posts
3
+ root 'posts#index'
4
+ # For details on the DSL available within this file, see http://guides.rubyonrails.org/routing.html
5
+ end
@@ -0,0 +1,34 @@
1
+ test:
2
+ service: Disk
3
+ root: <%= Rails.root.join("tmp/storage") %>
4
+
5
+ local:
6
+ service: Disk
7
+ root: <%= Rails.root.join("storage") %>
8
+
9
+ # Use bin/rails credentials:edit to set the AWS secrets (as aws:access_key_id|secret_access_key)
10
+ # amazon:
11
+ # service: S3
12
+ # access_key_id: <%= Rails.application.credentials.dig(:aws, :access_key_id) %>
13
+ # secret_access_key: <%= Rails.application.credentials.dig(:aws, :secret_access_key) %>
14
+ # region: us-east-1
15
+ # bucket: your_own_bucket-<%= Rails.env %>
16
+
17
+ # Remember not to checkin your GCS keyfile to a repository
18
+ # google:
19
+ # service: GCS
20
+ # project: your_project
21
+ # credentials: <%= Rails.root.join("path/to/gcs.keyfile") %>
22
+ # bucket: your_own_bucket-<%= Rails.env %>
23
+
24
+ # Use bin/rails credentials:edit to set the Azure Storage secret (as azure_storage:storage_access_key)
25
+ # microsoft:
26
+ # service: AzureStorage
27
+ # storage_account_name: your_account_name
28
+ # storage_access_key: <%= Rails.application.credentials.dig(:azure_storage, :storage_access_key) %>
29
+ # container: your_container_name-<%= Rails.env %>
30
+
31
+ # mirror:
32
+ # service: Mirror
33
+ # primary: local
34
+ # mirrors: [ amazon, google, microsoft ]
@@ -1,4 +1,6 @@
1
1
  # This file is used by Rack-based servers to start the application.
2
2
 
3
- require ::File.expand_path('../config/environment', __FILE__)
3
+ require_relative "config/environment"
4
+
4
5
  run Rails.application
6
+ Rails.application.load_server
@@ -0,0 +1,11 @@
1
+ class CreatePosts < ActiveRecord::Migration[7.2]
2
+ def change
3
+ create_table :posts do |t|
4
+ t.string :title
5
+ t.text :body
6
+ t.boolean :published
7
+
8
+ t.timestamps
9
+ end
10
+ end
11
+ end
@@ -0,0 +1,9 @@
1
+ # This file should ensure the existence of records required to run the application in every environment (production,
2
+ # development, test). The code here should be idempotent so that it can be executed at any point in every environment.
3
+ # The data can then be loaded with the bin/rails db:seed command (or created alongside the database with db:setup).
4
+ #
5
+ # Example:
6
+ #
7
+ # ["Action", "Comedy", "Drama", "Horror"].each do |genre_name|
8
+ # MovieGenre.find_or_create_by!(name: genre_name)
9
+ # end
@@ -0,0 +1,8 @@
1
+ {
2
+ "devDependencies": {
3
+ "@playwright/test": "^1.50.0",
4
+ "cypress": "^14.0.0",
5
+ "cypress-on-rails": "^0.1.0",
6
+ "playwright": "^1.50.0"
7
+ }
8
+ }