cypress-on-rails 1.17.0 → 1.19.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 (337) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/claude-code-review.yml +57 -0
  3. data/.github/workflows/claude.yml +50 -0
  4. data/.github/workflows/ruby.yml +14 -14
  5. data/CHANGELOG.md +319 -98
  6. data/README.md +271 -23
  7. data/RELEASING.md +200 -0
  8. data/Rakefile +1 -4
  9. data/cypress-on-rails.gemspec +1 -0
  10. data/docs/BEST_PRACTICES.md +678 -0
  11. data/docs/DX_IMPROVEMENTS.md +163 -0
  12. data/docs/PLAYWRIGHT_GUIDE.md +554 -0
  13. data/docs/RELEASE.md +124 -0
  14. data/docs/TROUBLESHOOTING.md +351 -0
  15. data/docs/VCR_GUIDE.md +499 -0
  16. data/docs/authentication.md +30 -0
  17. data/docs/factory_bot_associations.md +14 -0
  18. data/lib/cypress_on_rails/configuration.rb +29 -0
  19. data/lib/cypress_on_rails/railtie.rb +17 -2
  20. data/lib/cypress_on_rails/server.rb +197 -0
  21. data/lib/cypress_on_rails/state_reset_middleware.rb +58 -0
  22. data/lib/cypress_on_rails/vcr/insert_eject_middleware.rb +75 -0
  23. data/lib/cypress_on_rails/vcr/middleware_helpers.rb +51 -0
  24. data/lib/cypress_on_rails/vcr/use_cassette_middleware.rb +56 -0
  25. data/lib/cypress_on_rails/version.rb +1 -1
  26. data/lib/generators/cypress_on_rails/templates/config/initializers/cypress_on_rails.rb.erb +20 -0
  27. data/lib/generators/cypress_on_rails/templates/spec/cypress/e2e/rails_examples/using_factory_bot.cy.js +2 -2
  28. data/lib/generators/cypress_on_rails/templates/spec/cypress/e2e/rails_examples/using_scenarios.cy.js +1 -1
  29. data/lib/generators/cypress_on_rails/templates/spec/cypress/support/commands.js +22 -0
  30. data/lib/generators/cypress_on_rails/templates/spec/cypress/support/on-rails.js +2 -1
  31. data/lib/generators/cypress_on_rails/templates/spec/e2e/e2e_helper.rb.erb +0 -5
  32. data/lib/tasks/cypress.rake +33 -0
  33. data/rakelib/release.rake +80 -0
  34. data/rakelib/task_helpers.rb +23 -0
  35. data/rakelib/update_changelog.rake +63 -0
  36. data/spec/cypress_on_rails/configuration_spec.rb +4 -1
  37. data/spec/cypress_on_rails/vcr/insert_eject_middleware_spec.rb +177 -0
  38. data/spec/cypress_on_rails/vcr/use_cassette_middleware_spec.rb +68 -0
  39. data/specs_e2e/rails_6_1/.gitattributes +10 -0
  40. data/specs_e2e/rails_6_1/Gemfile +20 -0
  41. data/specs_e2e/{rails_5_2 → rails_6_1}/Rakefile +1 -1
  42. data/specs_e2e/rails_6_1/app/assets/stylesheets/application.css +15 -0
  43. data/specs_e2e/rails_6_1/app/jobs/application_job.rb +7 -0
  44. data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/layouts/application.html.erb +1 -1
  45. data/specs_e2e/rails_6_1/bin/bundle +114 -0
  46. data/specs_e2e/rails_6_1/bin/rails +5 -0
  47. data/specs_e2e/rails_6_1/bin/rake +5 -0
  48. data/specs_e2e/{rails_5_2 → rails_6_1}/bin/setup +15 -4
  49. data/specs_e2e/rails_6_1/bin/spring +14 -0
  50. data/specs_e2e/rails_6_1/bin/yarn +17 -0
  51. data/specs_e2e/rails_6_1/config/application.rb +34 -0
  52. data/specs_e2e/rails_6_1/config/boot.rb +4 -0
  53. data/specs_e2e/rails_6_1/config/cable.yml +10 -0
  54. data/specs_e2e/rails_6_1/config/credentials.yml.enc +1 -0
  55. data/specs_e2e/{rails_5_2 → rails_6_1}/config/database.yml +7 -0
  56. data/specs_e2e/{rails_5_2 → rails_6_1}/config/environment.rb +1 -1
  57. data/specs_e2e/{rails_5_2 → rails_6_1}/config/environments/development.rb +22 -5
  58. data/specs_e2e/rails_6_1/config/environments/production.rb +120 -0
  59. data/specs_e2e/{rails_5_2 → rails_6_1}/config/environments/test.rb +24 -7
  60. data/specs_e2e/rails_6_1/config/initializers/backtrace_silencers.rb +8 -0
  61. data/specs_e2e/{rails_5_2 → rails_6_1}/config/initializers/content_security_policy.rb +5 -0
  62. data/specs_e2e/{rails_4_2 → rails_6_1}/config/initializers/filter_parameter_logging.rb +3 -1
  63. data/specs_e2e/rails_6_1/config/initializers/permissions_policy.rb +11 -0
  64. data/specs_e2e/{rails_3_2 → rails_6_1}/config/initializers/wrap_parameters.rb +5 -1
  65. data/specs_e2e/{rails_5_2 → rails_6_1}/config/locales/en.yml +1 -1
  66. data/specs_e2e/rails_6_1/config/master.key +1 -0
  67. data/specs_e2e/rails_6_1/config/puma.rb +43 -0
  68. data/specs_e2e/rails_6_1/config/storage.yml +34 -0
  69. data/specs_e2e/{rails_5_2 → rails_6_1}/config.ru +2 -1
  70. data/specs_e2e/{rails_5_2 → rails_6_1}/db/migrate/20180621085832_create_posts.rb +1 -1
  71. data/specs_e2e/rails_6_1/package.json +8 -0
  72. data/specs_e2e/rails_6_1/playwright-report/index.html +71 -0
  73. data/specs_e2e/rails_6_1/public/robots.txt +1 -0
  74. data/specs_e2e/rails_6_1/test-results/.last-run.json +4 -0
  75. data/specs_e2e/{rails_4_2 → rails_6_1}/test.sh +22 -15
  76. data/specs_e2e/rails_7_2/.gitattributes +9 -0
  77. data/specs_e2e/rails_7_2/.gitignore +16 -0
  78. data/specs_e2e/rails_7_2/.rubocop.yml +8 -0
  79. data/specs_e2e/rails_7_2/Gemfile +11 -0
  80. data/specs_e2e/{rails_4_2 → rails_7_2}/Rakefile +1 -1
  81. data/specs_e2e/rails_7_2/app/assets/stylesheets/application.css +15 -0
  82. data/specs_e2e/rails_7_2/app/controllers/application_controller.rb +4 -0
  83. data/specs_e2e/rails_7_2/app/controllers/posts_controller.rb +58 -0
  84. data/specs_e2e/rails_7_2/app/helpers/posts_helper.rb +2 -0
  85. data/specs_e2e/rails_7_2/app/jobs/application_job.rb +7 -0
  86. data/specs_e2e/rails_7_2/app/models/application_record.rb +3 -0
  87. data/specs_e2e/rails_7_2/app/models/post.rb +2 -0
  88. data/specs_e2e/rails_7_2/app/views/layouts/application.html.erb +22 -0
  89. data/specs_e2e/rails_7_2/app/views/posts/_form.html.erb +32 -0
  90. data/specs_e2e/rails_7_2/app/views/posts/edit.html.erb +6 -0
  91. data/specs_e2e/rails_7_2/app/views/posts/index.html.erb +31 -0
  92. data/specs_e2e/rails_7_2/app/views/posts/new.html.erb +5 -0
  93. data/specs_e2e/rails_7_2/app/views/posts/show.html.erb +19 -0
  94. data/specs_e2e/rails_7_2/bin/brakeman +7 -0
  95. data/specs_e2e/rails_7_2/bin/bundle +109 -0
  96. data/specs_e2e/rails_7_2/bin/importmap +4 -0
  97. data/specs_e2e/rails_7_2/bin/rails +4 -0
  98. data/specs_e2e/rails_7_2/bin/rake +4 -0
  99. data/specs_e2e/rails_7_2/bin/setup +37 -0
  100. data/specs_e2e/rails_7_2/config/application.rb +37 -0
  101. data/specs_e2e/rails_7_2/config/boot.rb +4 -0
  102. data/specs_e2e/rails_7_2/config/cable.yml +10 -0
  103. data/specs_e2e/rails_7_2/config/credentials.yml.enc +1 -0
  104. data/specs_e2e/rails_7_2/config/database.yml +32 -0
  105. data/specs_e2e/{rails_4_2 → rails_7_2}/config/environment.rb +1 -1
  106. data/specs_e2e/rails_7_2/config/environments/development.rb +54 -0
  107. data/specs_e2e/rails_7_2/config/environments/production.rb +105 -0
  108. data/specs_e2e/rails_7_2/config/environments/test.rb +45 -0
  109. data/specs_e2e/rails_7_2/config/importmap.rb +7 -0
  110. data/specs_e2e/rails_7_2/config/initializers/content_security_policy.rb +25 -0
  111. data/specs_e2e/rails_7_2/config/initializers/filter_parameter_logging.rb +8 -0
  112. data/specs_e2e/{rails_5_2 → rails_7_2}/config/initializers/inflections.rb +4 -4
  113. data/specs_e2e/rails_7_2/config/initializers/permissions_policy.rb +13 -0
  114. data/specs_e2e/rails_7_2/config/locales/en.yml +31 -0
  115. data/specs_e2e/rails_7_2/config/master.key +1 -0
  116. data/specs_e2e/rails_7_2/config/puma.rb +34 -0
  117. data/specs_e2e/rails_7_2/config/routes.rb +5 -0
  118. data/specs_e2e/rails_7_2/config/storage.yml +34 -0
  119. data/specs_e2e/{rails_4_2 → rails_7_2}/config.ru +3 -1
  120. data/specs_e2e/rails_7_2/db/migrate/20180621085832_create_posts.rb +11 -0
  121. data/specs_e2e/rails_7_2/db/seeds.rb +9 -0
  122. data/specs_e2e/rails_7_2/db/test.sqlite3-shm +0 -0
  123. data/specs_e2e/rails_7_2/db/test.sqlite3-wal +0 -0
  124. data/specs_e2e/rails_7_2/package.json +8 -0
  125. data/specs_e2e/rails_7_2/playwright-report/index.html +71 -0
  126. data/specs_e2e/{rails_4_2 → rails_7_2}/public/404.html +6 -6
  127. data/specs_e2e/rails_7_2/public/406-unsupported-browser.html +66 -0
  128. data/specs_e2e/{rails_4_2 → rails_7_2}/public/422.html +6 -6
  129. data/specs_e2e/{rails_4_2 → rails_7_2}/public/500.html +6 -6
  130. data/specs_e2e/rails_7_2/public/icon.png +0 -0
  131. data/specs_e2e/rails_7_2/public/icon.svg +3 -0
  132. data/specs_e2e/rails_7_2/public/robots.txt +1 -0
  133. data/specs_e2e/rails_7_2/storage/test.sqlite3 +0 -0
  134. data/specs_e2e/rails_7_2/test/controllers/posts_controller_test.rb +48 -0
  135. data/specs_e2e/rails_7_2/test/cypress_fixtures/posts.yml +11 -0
  136. data/specs_e2e/rails_7_2/test/fixtures/posts.yml +11 -0
  137. data/specs_e2e/rails_7_2/test/models/post_test.rb +7 -0
  138. data/specs_e2e/rails_7_2/test-results/.last-run.json +4 -0
  139. data/specs_e2e/rails_7_2/test.sh +57 -0
  140. data/specs_e2e/rails_8/.gitattributes +9 -0
  141. data/specs_e2e/rails_8/.gitignore +16 -0
  142. data/specs_e2e/rails_8/.rubocop.yml +8 -0
  143. data/specs_e2e/rails_8/Gemfile +20 -0
  144. data/specs_e2e/{rails_3_2 → rails_8}/Rakefile +2 -3
  145. data/specs_e2e/rails_8/app/assets/stylesheets/application.css +10 -0
  146. data/specs_e2e/rails_8/app/controllers/application_controller.rb +4 -0
  147. data/specs_e2e/rails_8/app/controllers/posts_controller.rb +58 -0
  148. data/specs_e2e/rails_8/app/helpers/posts_helper.rb +2 -0
  149. data/specs_e2e/rails_8/app/jobs/application_job.rb +7 -0
  150. data/specs_e2e/rails_8/app/models/application_record.rb +3 -0
  151. data/specs_e2e/rails_8/app/models/post.rb +2 -0
  152. data/specs_e2e/rails_8/app/views/layouts/application.html.erb +27 -0
  153. data/specs_e2e/rails_8/app/views/posts/_form.html.erb +32 -0
  154. data/specs_e2e/rails_8/app/views/posts/edit.html.erb +6 -0
  155. data/specs_e2e/rails_8/app/views/posts/index.html.erb +31 -0
  156. data/specs_e2e/rails_8/app/views/posts/new.html.erb +5 -0
  157. data/specs_e2e/rails_8/app/views/posts/show.html.erb +19 -0
  158. data/specs_e2e/rails_8/bin/brakeman +7 -0
  159. data/specs_e2e/rails_8/bin/bundle +109 -0
  160. data/specs_e2e/rails_8/bin/dev +2 -0
  161. data/specs_e2e/rails_8/bin/importmap +4 -0
  162. data/specs_e2e/rails_8/bin/rails +4 -0
  163. data/specs_e2e/rails_8/bin/rake +4 -0
  164. data/specs_e2e/rails_8/bin/setup +34 -0
  165. data/specs_e2e/rails_8/bin/thrust +5 -0
  166. data/specs_e2e/rails_8/config/application.rb +27 -0
  167. data/specs_e2e/rails_8/config/boot.rb +4 -0
  168. data/specs_e2e/rails_8/config/cable.yml +17 -0
  169. data/specs_e2e/rails_8/config/cache.yml +16 -0
  170. data/specs_e2e/rails_8/config/credentials.yml.enc +1 -0
  171. data/specs_e2e/rails_8/config/database.yml +41 -0
  172. data/specs_e2e/rails_8/config/deploy.yml +116 -0
  173. data/specs_e2e/rails_8/config/environment.rb +5 -0
  174. data/specs_e2e/rails_8/config/environments/development.rb +57 -0
  175. data/specs_e2e/rails_8/config/environments/production.rb +90 -0
  176. data/specs_e2e/rails_8/config/environments/test.rb +45 -0
  177. data/specs_e2e/rails_8/config/importmap.rb +7 -0
  178. data/specs_e2e/rails_8/config/initializers/content_security_policy.rb +25 -0
  179. data/specs_e2e/rails_8/config/initializers/filter_parameter_logging.rb +8 -0
  180. data/specs_e2e/rails_8/config/initializers/inflections.rb +16 -0
  181. data/specs_e2e/rails_8/config/locales/en.yml +31 -0
  182. data/specs_e2e/rails_8/config/master.key +1 -0
  183. data/specs_e2e/rails_8/config/puma.rb +41 -0
  184. data/specs_e2e/rails_8/config/queue.yml +18 -0
  185. data/specs_e2e/rails_8/config/recurring.yml +10 -0
  186. data/specs_e2e/rails_8/config/routes.rb +5 -0
  187. data/specs_e2e/rails_8/config/storage.yml +34 -0
  188. data/specs_e2e/rails_8/config.ru +6 -0
  189. data/specs_e2e/rails_8/db/cable_schema.rb +11 -0
  190. data/specs_e2e/rails_8/db/cache_schema.rb +14 -0
  191. data/specs_e2e/rails_8/db/migrate/20180621085832_create_posts.rb +11 -0
  192. data/specs_e2e/rails_8/db/queue_schema.rb +129 -0
  193. data/specs_e2e/rails_8/db/seeds.rb +9 -0
  194. data/specs_e2e/rails_8/package.json +8 -0
  195. data/specs_e2e/rails_8/playwright-report/index.html +71 -0
  196. data/specs_e2e/rails_8/public/400.html +114 -0
  197. data/specs_e2e/rails_8/public/404.html +114 -0
  198. data/specs_e2e/rails_8/public/406-unsupported-browser.html +114 -0
  199. data/specs_e2e/rails_8/public/422.html +114 -0
  200. data/specs_e2e/rails_8/public/500.html +114 -0
  201. data/specs_e2e/rails_8/public/icon.png +0 -0
  202. data/specs_e2e/rails_8/public/icon.svg +3 -0
  203. data/specs_e2e/rails_8/public/robots.txt +1 -0
  204. data/specs_e2e/rails_8/storage/test.sqlite3 +0 -0
  205. data/specs_e2e/rails_8/storage/test.sqlite3-shm +0 -0
  206. data/specs_e2e/rails_8/storage/test.sqlite3-wal +0 -0
  207. data/specs_e2e/rails_8/test/application_system_test_case.rb +5 -0
  208. data/specs_e2e/rails_8/test/controllers/posts_controller_test.rb +48 -0
  209. data/specs_e2e/rails_8/test/cypress_fixtures/posts.yml +11 -0
  210. data/specs_e2e/rails_8/test/fixtures/posts.yml +11 -0
  211. data/specs_e2e/rails_8/test/models/post_test.rb +7 -0
  212. data/specs_e2e/rails_8/test/test_helper.rb +15 -0
  213. data/specs_e2e/rails_8/test-results/.last-run.json +4 -0
  214. data/specs_e2e/{rails_5_2 → rails_8}/test.sh +1 -1
  215. metadata +246 -150
  216. data/lib/cypress_on_rails/vcr_middleware.rb +0 -73
  217. data/spec/cypress_on_rails/vcr_middleware_spec.rb +0 -119
  218. data/specs_e2e/rails_3_2/.gitignore +0 -9
  219. data/specs_e2e/rails_3_2/.ruby_version +0 -1
  220. data/specs_e2e/rails_3_2/Gemfile +0 -7
  221. data/specs_e2e/rails_3_2/README.rdoc +0 -261
  222. data/specs_e2e/rails_3_2/app/assets/stylesheets/application.css +0 -13
  223. data/specs_e2e/rails_3_2/app/controllers/application_controller.rb +0 -3
  224. data/specs_e2e/rails_3_2/app/controllers/welcome_controller.rb +0 -4
  225. data/specs_e2e/rails_3_2/app/helpers/application_helper.rb +0 -2
  226. data/specs_e2e/rails_3_2/app/models/post.rb +0 -21
  227. data/specs_e2e/rails_3_2/app/views/layouts/application.html.erb +0 -13
  228. data/specs_e2e/rails_3_2/app/views/welcome/index.html.erb +0 -24
  229. data/specs_e2e/rails_3_2/bin/rails +0 -6
  230. data/specs_e2e/rails_3_2/config/application.rb +0 -68
  231. data/specs_e2e/rails_3_2/config/boot.rb +0 -6
  232. data/specs_e2e/rails_3_2/config/environment.rb +0 -5
  233. data/specs_e2e/rails_3_2/config/environments/development.rb +0 -31
  234. data/specs_e2e/rails_3_2/config/environments/production.rb +0 -64
  235. data/specs_e2e/rails_3_2/config/environments/test.rb +0 -35
  236. data/specs_e2e/rails_3_2/config/initializers/backtrace_silencers.rb +0 -7
  237. data/specs_e2e/rails_3_2/config/initializers/inflections.rb +0 -15
  238. data/specs_e2e/rails_3_2/config/initializers/mime_types.rb +0 -5
  239. data/specs_e2e/rails_3_2/config/initializers/secret_token.rb +0 -7
  240. data/specs_e2e/rails_3_2/config/initializers/session_store.rb +0 -8
  241. data/specs_e2e/rails_3_2/config/locales/en.yml +0 -5
  242. data/specs_e2e/rails_3_2/config/routes.rb +0 -60
  243. data/specs_e2e/rails_3_2/config.ru +0 -4
  244. data/specs_e2e/rails_3_2/public/404.html +0 -26
  245. data/specs_e2e/rails_3_2/public/422.html +0 -26
  246. data/specs_e2e/rails_3_2/public/500.html +0 -25
  247. data/specs_e2e/rails_3_2/public/robots.txt +0 -5
  248. data/specs_e2e/rails_3_2/test.sh +0 -50
  249. data/specs_e2e/rails_4_2/.gitignore +0 -12
  250. data/specs_e2e/rails_4_2/Gemfile +0 -11
  251. data/specs_e2e/rails_4_2/README.rdoc +0 -28
  252. data/specs_e2e/rails_4_2/app/assets/javascripts/using_vcr.js +0 -2
  253. data/specs_e2e/rails_4_2/app/assets/stylesheets/using_vcr.css +0 -4
  254. data/specs_e2e/rails_4_2/app/controllers/application_controller.rb +0 -5
  255. data/specs_e2e/rails_4_2/app/controllers/using_vcr_controller.rb +0 -10
  256. data/specs_e2e/rails_4_2/app/controllers/welcome_controller.rb +0 -4
  257. data/specs_e2e/rails_4_2/app/models/post.rb +0 -23
  258. data/specs_e2e/rails_4_2/app/views/layouts/application.html.erb +0 -12
  259. data/specs_e2e/rails_4_2/app/views/using_vcr/index.html.erb +0 -6
  260. data/specs_e2e/rails_4_2/app/views/using_vcr/record_cats.html.erb +0 -7
  261. data/specs_e2e/rails_4_2/app/views/welcome/index.html.erb +0 -24
  262. data/specs_e2e/rails_4_2/bin/bundle +0 -3
  263. data/specs_e2e/rails_4_2/bin/rails +0 -4
  264. data/specs_e2e/rails_4_2/bin/rake +0 -4
  265. data/specs_e2e/rails_4_2/bin/setup +0 -29
  266. data/specs_e2e/rails_4_2/config/application.rb +0 -32
  267. data/specs_e2e/rails_4_2/config/boot.rb +0 -3
  268. data/specs_e2e/rails_4_2/config/environments/development.rb +0 -25
  269. data/specs_e2e/rails_4_2/config/environments/production.rb +0 -64
  270. data/specs_e2e/rails_4_2/config/environments/test.rb +0 -42
  271. data/specs_e2e/rails_4_2/config/initializers/backtrace_silencers.rb +0 -7
  272. data/specs_e2e/rails_4_2/config/initializers/cookies_serializer.rb +0 -3
  273. data/specs_e2e/rails_4_2/config/initializers/session_store.rb +0 -3
  274. data/specs_e2e/rails_4_2/config/initializers/to_time_preserves_timezone.rb +0 -10
  275. data/specs_e2e/rails_4_2/config/initializers/wrap_parameters.rb +0 -9
  276. data/specs_e2e/rails_4_2/config/locales/en.yml +0 -23
  277. data/specs_e2e/rails_4_2/config/routes.rb +0 -61
  278. data/specs_e2e/rails_4_2/config/secrets.yml +0 -22
  279. data/specs_e2e/rails_4_2/package.json +0 -12
  280. data/specs_e2e/rails_4_2/playwright-report/index.html +0 -62
  281. data/specs_e2e/rails_4_2/public/favicon.ico +0 -0
  282. data/specs_e2e/rails_4_2/public/robots.txt +0 -5
  283. data/specs_e2e/rails_4_2/spec/fixtures/vcr_cassettes/cats.yml +0 -63
  284. data/specs_e2e/rails_5_2/Gemfile +0 -15
  285. data/specs_e2e/rails_5_2/app/assets/javascripts/posts.js +0 -2
  286. data/specs_e2e/rails_5_2/app/assets/stylesheets/posts.css +0 -4
  287. data/specs_e2e/rails_5_2/app/assets/stylesheets/scaffold.css +0 -80
  288. data/specs_e2e/rails_5_2/app/jobs/application_job.rb +0 -2
  289. data/specs_e2e/rails_5_2/app/views/welcome/index.html.erb +0 -5
  290. data/specs_e2e/rails_5_2/bin/bundle +0 -3
  291. data/specs_e2e/rails_5_2/bin/rails +0 -4
  292. data/specs_e2e/rails_5_2/bin/rake +0 -4
  293. data/specs_e2e/rails_5_2/bin/update +0 -25
  294. data/specs_e2e/rails_5_2/config/application.rb +0 -33
  295. data/specs_e2e/rails_5_2/config/boot.rb +0 -4
  296. data/specs_e2e/rails_5_2/config/credentials.yml.enc +0 -1
  297. data/specs_e2e/rails_5_2/config/environments/production.rb +0 -68
  298. data/specs_e2e/rails_5_2/config/initializers/backtrace_silencers.rb +0 -7
  299. data/specs_e2e/rails_5_2/config/initializers/filter_parameter_logging.rb +0 -4
  300. data/specs_e2e/rails_5_2/config/initializers/mime_types.rb +0 -4
  301. data/specs_e2e/rails_5_2/config/initializers/wrap_parameters.rb +0 -9
  302. data/specs_e2e/rails_5_2/config/master.key +0 -1
  303. data/specs_e2e/rails_5_2/public/favicon.ico +0 -0
  304. data/specs_e2e/rails_5_2/public/robots.txt +0 -1
  305. /data/specs_e2e/{rails_5_2 → rails_6_1}/.gitignore +0 -0
  306. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/controllers/application_controller.rb +0 -0
  307. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/controllers/posts_controller.rb +0 -0
  308. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/helpers/posts_helper.rb +0 -0
  309. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/models/application_record.rb +0 -0
  310. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/models/post.rb +0 -0
  311. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/_form.html.erb +0 -0
  312. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/edit.html.erb +0 -0
  313. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/index.html.erb +0 -0
  314. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/new.html.erb +0 -0
  315. /data/specs_e2e/{rails_5_2 → rails_6_1}/app/views/posts/show.html.erb +0 -0
  316. /data/specs_e2e/{rails_5_2 → rails_6_1}/config/initializers/application_controller_renderer.rb +0 -0
  317. /data/specs_e2e/{rails_5_2 → rails_6_1}/config/initializers/cookies_serializer.rb +0 -0
  318. /data/specs_e2e/{rails_4_2 → rails_6_1}/config/initializers/inflections.rb +0 -0
  319. /data/specs_e2e/{rails_4_2 → rails_6_1}/config/initializers/mime_types.rb +0 -0
  320. /data/specs_e2e/{rails_5_2 → rails_6_1}/config/routes.rb +0 -0
  321. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/404.html +0 -0
  322. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/422.html +0 -0
  323. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/500.html +0 -0
  324. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/apple-touch-icon-precomposed.png +0 -0
  325. /data/specs_e2e/{rails_5_2 → rails_6_1}/public/apple-touch-icon.png +0 -0
  326. /data/specs_e2e/{rails_3_2 → rails_6_1}/public/favicon.ico +0 -0
  327. /data/specs_e2e/{rails_5_2 → rails_6_1}/test/controllers/posts_controller_test.rb +0 -0
  328. /data/specs_e2e/{rails_5_2 → rails_6_1}/test/cypress_fixtures/posts.yml +0 -0
  329. /data/specs_e2e/{rails_5_2 → rails_6_1}/test/fixtures/posts.yml +0 -0
  330. /data/specs_e2e/{rails_5_2 → rails_6_1}/test/models/post_test.rb +0 -0
  331. /data/specs_e2e/{rails_3_2/log → rails_6_1/vendor}/.keep +0 -0
  332. /data/specs_e2e/{rails_3_2/tmp → rails_7_2/vendor}/.keep +0 -0
  333. /data/specs_e2e/{rails_4_2/spec → rails_7_2/vendor/javascript}/.keep +0 -0
  334. /data/specs_e2e/{rails_5_2 → rails_8}/README.md +0 -0
  335. /data/specs_e2e/{rails_4_2/vendor → rails_8/storage}/.keep +0 -0
  336. /data/specs_e2e/{rails_5_2 → rails_8}/vendor/.keep +0 -0
  337. /data/specs_e2e/{rails_3_2/vendor/.gitkeep → rails_8/vendor/javascript/.keep} +0 -0
@@ -0,0 +1,11 @@
1
+ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2
+
3
+ one:
4
+ title: MyCypressFixtures
5
+ body: MyText
6
+ published: true
7
+
8
+ two:
9
+ title: MyCypressFixtures2
10
+ body: MyText
11
+ published: true
@@ -0,0 +1,11 @@
1
+ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
2
+
3
+ one:
4
+ title: MyRailsFixtures
5
+ body: MyText
6
+ published: false
7
+
8
+ two:
9
+ title: MyRailsFixtures2
10
+ body: MyText
11
+ published: false
@@ -0,0 +1,7 @@
1
+ require 'test_helper'
2
+
3
+ class PostTest < ActiveSupport::TestCase
4
+ # test "the truth" do
5
+ # assert true
6
+ # end
7
+ end
@@ -0,0 +1,15 @@
1
+ ENV["RAILS_ENV"] ||= "test"
2
+ require_relative "../config/environment"
3
+ require "rails/test_help"
4
+
5
+ module ActiveSupport
6
+ class TestCase
7
+ # Run tests in parallel with specified workers
8
+ parallelize(workers: :number_of_processors)
9
+
10
+ # Setup all fixtures in test/fixtures/*.yml for all tests in alphabetical order.
11
+ fixtures :all
12
+
13
+ # Add more helper methods to be used by all tests here...
14
+ end
15
+ end
@@ -0,0 +1,4 @@
1
+ {
2
+ "status": "passed",
3
+ "failedTests": []
4
+ }
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env bash
2
2
  set -eo pipefail
3
3
 
4
- echo '--- testing rails 5.2'
4
+ echo '--- testing rails 8'
5
5
 
6
6
  echo '-- setting environment'
7
7
  export DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
metadata CHANGED
@@ -1,15 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cypress-on-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.17.0
4
+ version: 1.19.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - miceportal team
8
8
  - Grant Petersen-Speelman
9
- autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2024-01-28 00:00:00.000000000 Z
11
+ date: 1980-01-02 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: rack
@@ -95,6 +94,20 @@ dependencies:
95
94
  - - ">="
96
95
  - !ruby/object:Gem::Version
97
96
  version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: gem-release
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
98
111
  description: Integrates cypress with rails or rack applications
99
112
  email:
100
113
  - info@miceportal.de
@@ -104,6 +117,8 @@ extensions: []
104
117
  extra_rdoc_files: []
105
118
  files:
106
119
  - ".github/FUNDING.yml"
120
+ - ".github/workflows/claude-code-review.yml"
121
+ - ".github/workflows/claude.yml"
107
122
  - ".github/workflows/ruby.yml"
108
123
  - ".gitignore"
109
124
  - ".rspec"
@@ -111,8 +126,15 @@ files:
111
126
  - Gemfile
112
127
  - LICENSE
113
128
  - README.md
129
+ - RELEASING.md
114
130
  - Rakefile
115
131
  - cypress-on-rails.gemspec
132
+ - docs/BEST_PRACTICES.md
133
+ - docs/DX_IMPROVEMENTS.md
134
+ - docs/PLAYWRIGHT_GUIDE.md
135
+ - docs/RELEASE.md
136
+ - docs/TROUBLESHOOTING.md
137
+ - docs/VCR_GUIDE.md
116
138
  - docs/authentication.md
117
139
  - docs/factory_bot_associations.md
118
140
  - lib/cypress-on-rails.rb
@@ -125,9 +147,13 @@ files:
125
147
  - lib/cypress_on_rails/middleware.rb
126
148
  - lib/cypress_on_rails/middleware_config.rb
127
149
  - lib/cypress_on_rails/railtie.rb
150
+ - lib/cypress_on_rails/server.rb
128
151
  - lib/cypress_on_rails/simple_rails_factory.rb
129
152
  - lib/cypress_on_rails/smart_factory_wrapper.rb
130
- - lib/cypress_on_rails/vcr_middleware.rb
153
+ - lib/cypress_on_rails/state_reset_middleware.rb
154
+ - lib/cypress_on_rails/vcr/insert_eject_middleware.rb
155
+ - lib/cypress_on_rails/vcr/middleware_helpers.rb
156
+ - lib/cypress_on_rails/vcr/use_cassette_middleware.rb
131
157
  - lib/cypress_on_rails/version.rb
132
158
  - lib/generators/cypress_on_rails/install_generator.rb
133
159
  - lib/generators/cypress_on_rails/templates/config/initializers/cypress_on_rails.rb.erb
@@ -152,10 +178,14 @@ files:
152
178
  - lib/generators/cypress_on_rails/templates/spec/playwright/e2e/rails_examples/using_scenarios.spec.js
153
179
  - lib/generators/cypress_on_rails/templates/spec/playwright/support/index.js.erb
154
180
  - lib/generators/cypress_on_rails/templates/spec/playwright/support/on-rails.js
181
+ - lib/tasks/cypress.rake
155
182
  - plugin/.gitignore
156
183
  - plugin/cypress/plugins/index.js
157
184
  - plugin/package.json
158
185
  - plugin/support/index.js
186
+ - rakelib/release.rake
187
+ - rakelib/task_helpers.rb
188
+ - rakelib/update_changelog.rake
159
189
  - spec/cypress_on_rails/command_executor/e2e_helper.rb
160
190
  - spec/cypress_on_rails/command_executor/test_command.rb
161
191
  - spec/cypress_on_rails/command_executor/test_command_with_options.rb
@@ -165,153 +195,220 @@ files:
165
195
  - spec/cypress_on_rails/railtie_spec.rb
166
196
  - spec/cypress_on_rails/simple_rails_factory_spec.rb
167
197
  - spec/cypress_on_rails/smart_factory_wrapper_spec.rb
168
- - spec/cypress_on_rails/vcr_middleware_spec.rb
198
+ - spec/cypress_on_rails/vcr/insert_eject_middleware_spec.rb
199
+ - spec/cypress_on_rails/vcr/use_cassette_middleware_spec.rb
169
200
  - spec/spec_helper.rb
170
201
  - specs_e2e/cypress.config.js
171
202
  - specs_e2e/playwright.config.js
172
- - specs_e2e/rails_3_2/.gitignore
173
- - specs_e2e/rails_3_2/.ruby_version
174
- - specs_e2e/rails_3_2/Gemfile
175
- - specs_e2e/rails_3_2/README.rdoc
176
- - specs_e2e/rails_3_2/Rakefile
177
- - specs_e2e/rails_3_2/app/assets/stylesheets/application.css
178
- - specs_e2e/rails_3_2/app/controllers/application_controller.rb
179
- - specs_e2e/rails_3_2/app/controllers/welcome_controller.rb
180
- - specs_e2e/rails_3_2/app/helpers/application_helper.rb
181
- - specs_e2e/rails_3_2/app/models/post.rb
182
- - specs_e2e/rails_3_2/app/views/layouts/application.html.erb
183
- - specs_e2e/rails_3_2/app/views/welcome/index.html.erb
184
- - specs_e2e/rails_3_2/bin/rails
185
- - specs_e2e/rails_3_2/config.ru
186
- - specs_e2e/rails_3_2/config/application.rb
187
- - specs_e2e/rails_3_2/config/boot.rb
188
- - specs_e2e/rails_3_2/config/environment.rb
189
- - specs_e2e/rails_3_2/config/environments/development.rb
190
- - specs_e2e/rails_3_2/config/environments/production.rb
191
- - specs_e2e/rails_3_2/config/environments/test.rb
192
- - specs_e2e/rails_3_2/config/initializers/backtrace_silencers.rb
193
- - specs_e2e/rails_3_2/config/initializers/inflections.rb
194
- - specs_e2e/rails_3_2/config/initializers/mime_types.rb
195
- - specs_e2e/rails_3_2/config/initializers/secret_token.rb
196
- - specs_e2e/rails_3_2/config/initializers/session_store.rb
197
- - specs_e2e/rails_3_2/config/initializers/wrap_parameters.rb
198
- - specs_e2e/rails_3_2/config/locales/en.yml
199
- - specs_e2e/rails_3_2/config/routes.rb
200
- - specs_e2e/rails_3_2/log/.keep
201
- - specs_e2e/rails_3_2/public/404.html
202
- - specs_e2e/rails_3_2/public/422.html
203
- - specs_e2e/rails_3_2/public/500.html
204
- - specs_e2e/rails_3_2/public/favicon.ico
205
- - specs_e2e/rails_3_2/public/robots.txt
206
- - specs_e2e/rails_3_2/test.sh
207
- - specs_e2e/rails_3_2/tmp/.keep
208
- - specs_e2e/rails_3_2/vendor/.gitkeep
209
- - specs_e2e/rails_4_2/.gitignore
210
- - specs_e2e/rails_4_2/Gemfile
211
- - specs_e2e/rails_4_2/README.rdoc
212
- - specs_e2e/rails_4_2/Rakefile
213
- - specs_e2e/rails_4_2/app/assets/javascripts/using_vcr.js
214
- - specs_e2e/rails_4_2/app/assets/stylesheets/using_vcr.css
215
- - specs_e2e/rails_4_2/app/controllers/application_controller.rb
216
- - specs_e2e/rails_4_2/app/controllers/using_vcr_controller.rb
217
- - specs_e2e/rails_4_2/app/controllers/welcome_controller.rb
218
- - specs_e2e/rails_4_2/app/models/post.rb
219
- - specs_e2e/rails_4_2/app/views/layouts/application.html.erb
220
- - specs_e2e/rails_4_2/app/views/using_vcr/index.html.erb
221
- - specs_e2e/rails_4_2/app/views/using_vcr/record_cats.html.erb
222
- - specs_e2e/rails_4_2/app/views/welcome/index.html.erb
223
- - specs_e2e/rails_4_2/bin/bundle
224
- - specs_e2e/rails_4_2/bin/rails
225
- - specs_e2e/rails_4_2/bin/rake
226
- - specs_e2e/rails_4_2/bin/setup
227
- - specs_e2e/rails_4_2/config.ru
228
- - specs_e2e/rails_4_2/config/application.rb
229
- - specs_e2e/rails_4_2/config/boot.rb
230
- - specs_e2e/rails_4_2/config/environment.rb
231
- - specs_e2e/rails_4_2/config/environments/development.rb
232
- - specs_e2e/rails_4_2/config/environments/production.rb
233
- - specs_e2e/rails_4_2/config/environments/test.rb
234
- - specs_e2e/rails_4_2/config/initializers/backtrace_silencers.rb
235
- - specs_e2e/rails_4_2/config/initializers/cookies_serializer.rb
236
- - specs_e2e/rails_4_2/config/initializers/filter_parameter_logging.rb
237
- - specs_e2e/rails_4_2/config/initializers/inflections.rb
238
- - specs_e2e/rails_4_2/config/initializers/mime_types.rb
239
- - specs_e2e/rails_4_2/config/initializers/session_store.rb
240
- - specs_e2e/rails_4_2/config/initializers/to_time_preserves_timezone.rb
241
- - specs_e2e/rails_4_2/config/initializers/wrap_parameters.rb
242
- - specs_e2e/rails_4_2/config/locales/en.yml
243
- - specs_e2e/rails_4_2/config/routes.rb
244
- - specs_e2e/rails_4_2/config/secrets.yml
245
- - specs_e2e/rails_4_2/package.json
246
- - specs_e2e/rails_4_2/playwright-report/index.html
247
- - specs_e2e/rails_4_2/public/404.html
248
- - specs_e2e/rails_4_2/public/422.html
249
- - specs_e2e/rails_4_2/public/500.html
250
- - specs_e2e/rails_4_2/public/favicon.ico
251
- - specs_e2e/rails_4_2/public/robots.txt
252
- - specs_e2e/rails_4_2/spec/.keep
253
- - specs_e2e/rails_4_2/spec/fixtures/vcr_cassettes/cats.yml
254
- - specs_e2e/rails_4_2/test.sh
255
- - specs_e2e/rails_4_2/vendor/.keep
256
- - specs_e2e/rails_5_2/.gitignore
257
- - specs_e2e/rails_5_2/Gemfile
258
- - specs_e2e/rails_5_2/README.md
259
- - specs_e2e/rails_5_2/Rakefile
260
- - specs_e2e/rails_5_2/app/assets/javascripts/posts.js
261
- - specs_e2e/rails_5_2/app/assets/stylesheets/posts.css
262
- - specs_e2e/rails_5_2/app/assets/stylesheets/scaffold.css
263
- - specs_e2e/rails_5_2/app/controllers/application_controller.rb
264
- - specs_e2e/rails_5_2/app/controllers/posts_controller.rb
265
- - specs_e2e/rails_5_2/app/helpers/posts_helper.rb
266
- - specs_e2e/rails_5_2/app/jobs/application_job.rb
267
- - specs_e2e/rails_5_2/app/models/application_record.rb
268
- - specs_e2e/rails_5_2/app/models/post.rb
269
- - specs_e2e/rails_5_2/app/views/layouts/application.html.erb
270
- - specs_e2e/rails_5_2/app/views/posts/_form.html.erb
271
- - specs_e2e/rails_5_2/app/views/posts/edit.html.erb
272
- - specs_e2e/rails_5_2/app/views/posts/index.html.erb
273
- - specs_e2e/rails_5_2/app/views/posts/new.html.erb
274
- - specs_e2e/rails_5_2/app/views/posts/show.html.erb
275
- - specs_e2e/rails_5_2/app/views/welcome/index.html.erb
276
- - specs_e2e/rails_5_2/bin/bundle
277
- - specs_e2e/rails_5_2/bin/rails
278
- - specs_e2e/rails_5_2/bin/rake
279
- - specs_e2e/rails_5_2/bin/setup
280
- - specs_e2e/rails_5_2/bin/update
281
- - specs_e2e/rails_5_2/config.ru
282
- - specs_e2e/rails_5_2/config/application.rb
283
- - specs_e2e/rails_5_2/config/boot.rb
284
- - specs_e2e/rails_5_2/config/credentials.yml.enc
285
- - specs_e2e/rails_5_2/config/database.yml
286
- - specs_e2e/rails_5_2/config/environment.rb
287
- - specs_e2e/rails_5_2/config/environments/development.rb
288
- - specs_e2e/rails_5_2/config/environments/production.rb
289
- - specs_e2e/rails_5_2/config/environments/test.rb
290
- - specs_e2e/rails_5_2/config/initializers/application_controller_renderer.rb
291
- - specs_e2e/rails_5_2/config/initializers/backtrace_silencers.rb
292
- - specs_e2e/rails_5_2/config/initializers/content_security_policy.rb
293
- - specs_e2e/rails_5_2/config/initializers/cookies_serializer.rb
294
- - specs_e2e/rails_5_2/config/initializers/filter_parameter_logging.rb
295
- - specs_e2e/rails_5_2/config/initializers/inflections.rb
296
- - specs_e2e/rails_5_2/config/initializers/mime_types.rb
297
- - specs_e2e/rails_5_2/config/initializers/wrap_parameters.rb
298
- - specs_e2e/rails_5_2/config/locales/en.yml
299
- - specs_e2e/rails_5_2/config/master.key
300
- - specs_e2e/rails_5_2/config/routes.rb
301
- - specs_e2e/rails_5_2/db/migrate/20180621085832_create_posts.rb
302
- - specs_e2e/rails_5_2/public/404.html
303
- - specs_e2e/rails_5_2/public/422.html
304
- - specs_e2e/rails_5_2/public/500.html
305
- - specs_e2e/rails_5_2/public/apple-touch-icon-precomposed.png
306
- - specs_e2e/rails_5_2/public/apple-touch-icon.png
307
- - specs_e2e/rails_5_2/public/favicon.ico
308
- - specs_e2e/rails_5_2/public/robots.txt
309
- - specs_e2e/rails_5_2/test.sh
310
- - specs_e2e/rails_5_2/test/controllers/posts_controller_test.rb
311
- - specs_e2e/rails_5_2/test/cypress_fixtures/posts.yml
312
- - specs_e2e/rails_5_2/test/fixtures/posts.yml
313
- - specs_e2e/rails_5_2/test/models/post_test.rb
314
- - specs_e2e/rails_5_2/vendor/.keep
203
+ - specs_e2e/rails_6_1/.gitattributes
204
+ - specs_e2e/rails_6_1/.gitignore
205
+ - specs_e2e/rails_6_1/Gemfile
206
+ - specs_e2e/rails_6_1/Rakefile
207
+ - specs_e2e/rails_6_1/app/assets/stylesheets/application.css
208
+ - specs_e2e/rails_6_1/app/controllers/application_controller.rb
209
+ - specs_e2e/rails_6_1/app/controllers/posts_controller.rb
210
+ - specs_e2e/rails_6_1/app/helpers/posts_helper.rb
211
+ - specs_e2e/rails_6_1/app/jobs/application_job.rb
212
+ - specs_e2e/rails_6_1/app/models/application_record.rb
213
+ - specs_e2e/rails_6_1/app/models/post.rb
214
+ - specs_e2e/rails_6_1/app/views/layouts/application.html.erb
215
+ - specs_e2e/rails_6_1/app/views/posts/_form.html.erb
216
+ - specs_e2e/rails_6_1/app/views/posts/edit.html.erb
217
+ - specs_e2e/rails_6_1/app/views/posts/index.html.erb
218
+ - specs_e2e/rails_6_1/app/views/posts/new.html.erb
219
+ - specs_e2e/rails_6_1/app/views/posts/show.html.erb
220
+ - specs_e2e/rails_6_1/bin/bundle
221
+ - specs_e2e/rails_6_1/bin/rails
222
+ - specs_e2e/rails_6_1/bin/rake
223
+ - specs_e2e/rails_6_1/bin/setup
224
+ - specs_e2e/rails_6_1/bin/spring
225
+ - specs_e2e/rails_6_1/bin/yarn
226
+ - specs_e2e/rails_6_1/config.ru
227
+ - specs_e2e/rails_6_1/config/application.rb
228
+ - specs_e2e/rails_6_1/config/boot.rb
229
+ - specs_e2e/rails_6_1/config/cable.yml
230
+ - specs_e2e/rails_6_1/config/credentials.yml.enc
231
+ - specs_e2e/rails_6_1/config/database.yml
232
+ - specs_e2e/rails_6_1/config/environment.rb
233
+ - specs_e2e/rails_6_1/config/environments/development.rb
234
+ - specs_e2e/rails_6_1/config/environments/production.rb
235
+ - specs_e2e/rails_6_1/config/environments/test.rb
236
+ - specs_e2e/rails_6_1/config/initializers/application_controller_renderer.rb
237
+ - specs_e2e/rails_6_1/config/initializers/backtrace_silencers.rb
238
+ - specs_e2e/rails_6_1/config/initializers/content_security_policy.rb
239
+ - specs_e2e/rails_6_1/config/initializers/cookies_serializer.rb
240
+ - specs_e2e/rails_6_1/config/initializers/filter_parameter_logging.rb
241
+ - specs_e2e/rails_6_1/config/initializers/inflections.rb
242
+ - specs_e2e/rails_6_1/config/initializers/mime_types.rb
243
+ - specs_e2e/rails_6_1/config/initializers/permissions_policy.rb
244
+ - specs_e2e/rails_6_1/config/initializers/wrap_parameters.rb
245
+ - specs_e2e/rails_6_1/config/locales/en.yml
246
+ - specs_e2e/rails_6_1/config/master.key
247
+ - specs_e2e/rails_6_1/config/puma.rb
248
+ - specs_e2e/rails_6_1/config/routes.rb
249
+ - specs_e2e/rails_6_1/config/storage.yml
250
+ - specs_e2e/rails_6_1/db/migrate/20180621085832_create_posts.rb
251
+ - specs_e2e/rails_6_1/package.json
252
+ - specs_e2e/rails_6_1/playwright-report/index.html
253
+ - specs_e2e/rails_6_1/public/404.html
254
+ - specs_e2e/rails_6_1/public/422.html
255
+ - specs_e2e/rails_6_1/public/500.html
256
+ - specs_e2e/rails_6_1/public/apple-touch-icon-precomposed.png
257
+ - specs_e2e/rails_6_1/public/apple-touch-icon.png
258
+ - specs_e2e/rails_6_1/public/favicon.ico
259
+ - specs_e2e/rails_6_1/public/robots.txt
260
+ - specs_e2e/rails_6_1/test-results/.last-run.json
261
+ - specs_e2e/rails_6_1/test.sh
262
+ - specs_e2e/rails_6_1/test/controllers/posts_controller_test.rb
263
+ - specs_e2e/rails_6_1/test/cypress_fixtures/posts.yml
264
+ - specs_e2e/rails_6_1/test/fixtures/posts.yml
265
+ - specs_e2e/rails_6_1/test/models/post_test.rb
266
+ - specs_e2e/rails_6_1/vendor/.keep
267
+ - specs_e2e/rails_7_2/.gitattributes
268
+ - specs_e2e/rails_7_2/.gitignore
269
+ - specs_e2e/rails_7_2/.rubocop.yml
270
+ - specs_e2e/rails_7_2/Gemfile
271
+ - specs_e2e/rails_7_2/Rakefile
272
+ - specs_e2e/rails_7_2/app/assets/stylesheets/application.css
273
+ - specs_e2e/rails_7_2/app/controllers/application_controller.rb
274
+ - specs_e2e/rails_7_2/app/controllers/posts_controller.rb
275
+ - specs_e2e/rails_7_2/app/helpers/posts_helper.rb
276
+ - specs_e2e/rails_7_2/app/jobs/application_job.rb
277
+ - specs_e2e/rails_7_2/app/models/application_record.rb
278
+ - specs_e2e/rails_7_2/app/models/post.rb
279
+ - specs_e2e/rails_7_2/app/views/layouts/application.html.erb
280
+ - specs_e2e/rails_7_2/app/views/posts/_form.html.erb
281
+ - specs_e2e/rails_7_2/app/views/posts/edit.html.erb
282
+ - specs_e2e/rails_7_2/app/views/posts/index.html.erb
283
+ - specs_e2e/rails_7_2/app/views/posts/new.html.erb
284
+ - specs_e2e/rails_7_2/app/views/posts/show.html.erb
285
+ - specs_e2e/rails_7_2/bin/brakeman
286
+ - specs_e2e/rails_7_2/bin/bundle
287
+ - specs_e2e/rails_7_2/bin/importmap
288
+ - specs_e2e/rails_7_2/bin/rails
289
+ - specs_e2e/rails_7_2/bin/rake
290
+ - specs_e2e/rails_7_2/bin/setup
291
+ - specs_e2e/rails_7_2/config.ru
292
+ - specs_e2e/rails_7_2/config/application.rb
293
+ - specs_e2e/rails_7_2/config/boot.rb
294
+ - specs_e2e/rails_7_2/config/cable.yml
295
+ - specs_e2e/rails_7_2/config/credentials.yml.enc
296
+ - specs_e2e/rails_7_2/config/database.yml
297
+ - specs_e2e/rails_7_2/config/environment.rb
298
+ - specs_e2e/rails_7_2/config/environments/development.rb
299
+ - specs_e2e/rails_7_2/config/environments/production.rb
300
+ - specs_e2e/rails_7_2/config/environments/test.rb
301
+ - specs_e2e/rails_7_2/config/importmap.rb
302
+ - specs_e2e/rails_7_2/config/initializers/content_security_policy.rb
303
+ - specs_e2e/rails_7_2/config/initializers/filter_parameter_logging.rb
304
+ - specs_e2e/rails_7_2/config/initializers/inflections.rb
305
+ - specs_e2e/rails_7_2/config/initializers/permissions_policy.rb
306
+ - specs_e2e/rails_7_2/config/locales/en.yml
307
+ - specs_e2e/rails_7_2/config/master.key
308
+ - specs_e2e/rails_7_2/config/puma.rb
309
+ - specs_e2e/rails_7_2/config/routes.rb
310
+ - specs_e2e/rails_7_2/config/storage.yml
311
+ - specs_e2e/rails_7_2/db/migrate/20180621085832_create_posts.rb
312
+ - specs_e2e/rails_7_2/db/seeds.rb
313
+ - specs_e2e/rails_7_2/db/test.sqlite3-shm
314
+ - specs_e2e/rails_7_2/db/test.sqlite3-wal
315
+ - specs_e2e/rails_7_2/package.json
316
+ - specs_e2e/rails_7_2/playwright-report/index.html
317
+ - specs_e2e/rails_7_2/public/404.html
318
+ - specs_e2e/rails_7_2/public/406-unsupported-browser.html
319
+ - specs_e2e/rails_7_2/public/422.html
320
+ - specs_e2e/rails_7_2/public/500.html
321
+ - specs_e2e/rails_7_2/public/icon.png
322
+ - specs_e2e/rails_7_2/public/icon.svg
323
+ - specs_e2e/rails_7_2/public/robots.txt
324
+ - specs_e2e/rails_7_2/storage/test.sqlite3
325
+ - specs_e2e/rails_7_2/test-results/.last-run.json
326
+ - specs_e2e/rails_7_2/test.sh
327
+ - specs_e2e/rails_7_2/test/controllers/posts_controller_test.rb
328
+ - specs_e2e/rails_7_2/test/cypress_fixtures/posts.yml
329
+ - specs_e2e/rails_7_2/test/fixtures/posts.yml
330
+ - specs_e2e/rails_7_2/test/models/post_test.rb
331
+ - specs_e2e/rails_7_2/vendor/.keep
332
+ - specs_e2e/rails_7_2/vendor/javascript/.keep
333
+ - specs_e2e/rails_8/.gitattributes
334
+ - specs_e2e/rails_8/.gitignore
335
+ - specs_e2e/rails_8/.rubocop.yml
336
+ - specs_e2e/rails_8/Gemfile
337
+ - specs_e2e/rails_8/README.md
338
+ - specs_e2e/rails_8/Rakefile
339
+ - specs_e2e/rails_8/app/assets/stylesheets/application.css
340
+ - specs_e2e/rails_8/app/controllers/application_controller.rb
341
+ - specs_e2e/rails_8/app/controllers/posts_controller.rb
342
+ - specs_e2e/rails_8/app/helpers/posts_helper.rb
343
+ - specs_e2e/rails_8/app/jobs/application_job.rb
344
+ - specs_e2e/rails_8/app/models/application_record.rb
345
+ - specs_e2e/rails_8/app/models/post.rb
346
+ - specs_e2e/rails_8/app/views/layouts/application.html.erb
347
+ - specs_e2e/rails_8/app/views/posts/_form.html.erb
348
+ - specs_e2e/rails_8/app/views/posts/edit.html.erb
349
+ - specs_e2e/rails_8/app/views/posts/index.html.erb
350
+ - specs_e2e/rails_8/app/views/posts/new.html.erb
351
+ - specs_e2e/rails_8/app/views/posts/show.html.erb
352
+ - specs_e2e/rails_8/bin/brakeman
353
+ - specs_e2e/rails_8/bin/bundle
354
+ - specs_e2e/rails_8/bin/dev
355
+ - specs_e2e/rails_8/bin/importmap
356
+ - specs_e2e/rails_8/bin/rails
357
+ - specs_e2e/rails_8/bin/rake
358
+ - specs_e2e/rails_8/bin/setup
359
+ - specs_e2e/rails_8/bin/thrust
360
+ - specs_e2e/rails_8/config.ru
361
+ - specs_e2e/rails_8/config/application.rb
362
+ - specs_e2e/rails_8/config/boot.rb
363
+ - specs_e2e/rails_8/config/cable.yml
364
+ - specs_e2e/rails_8/config/cache.yml
365
+ - specs_e2e/rails_8/config/credentials.yml.enc
366
+ - specs_e2e/rails_8/config/database.yml
367
+ - specs_e2e/rails_8/config/deploy.yml
368
+ - specs_e2e/rails_8/config/environment.rb
369
+ - specs_e2e/rails_8/config/environments/development.rb
370
+ - specs_e2e/rails_8/config/environments/production.rb
371
+ - specs_e2e/rails_8/config/environments/test.rb
372
+ - specs_e2e/rails_8/config/importmap.rb
373
+ - specs_e2e/rails_8/config/initializers/content_security_policy.rb
374
+ - specs_e2e/rails_8/config/initializers/filter_parameter_logging.rb
375
+ - specs_e2e/rails_8/config/initializers/inflections.rb
376
+ - specs_e2e/rails_8/config/locales/en.yml
377
+ - specs_e2e/rails_8/config/master.key
378
+ - specs_e2e/rails_8/config/puma.rb
379
+ - specs_e2e/rails_8/config/queue.yml
380
+ - specs_e2e/rails_8/config/recurring.yml
381
+ - specs_e2e/rails_8/config/routes.rb
382
+ - specs_e2e/rails_8/config/storage.yml
383
+ - specs_e2e/rails_8/db/cable_schema.rb
384
+ - specs_e2e/rails_8/db/cache_schema.rb
385
+ - specs_e2e/rails_8/db/migrate/20180621085832_create_posts.rb
386
+ - specs_e2e/rails_8/db/queue_schema.rb
387
+ - specs_e2e/rails_8/db/seeds.rb
388
+ - specs_e2e/rails_8/package.json
389
+ - specs_e2e/rails_8/playwright-report/index.html
390
+ - specs_e2e/rails_8/public/400.html
391
+ - specs_e2e/rails_8/public/404.html
392
+ - specs_e2e/rails_8/public/406-unsupported-browser.html
393
+ - specs_e2e/rails_8/public/422.html
394
+ - specs_e2e/rails_8/public/500.html
395
+ - specs_e2e/rails_8/public/icon.png
396
+ - specs_e2e/rails_8/public/icon.svg
397
+ - specs_e2e/rails_8/public/robots.txt
398
+ - specs_e2e/rails_8/storage/.keep
399
+ - specs_e2e/rails_8/storage/test.sqlite3
400
+ - specs_e2e/rails_8/storage/test.sqlite3-shm
401
+ - specs_e2e/rails_8/storage/test.sqlite3-wal
402
+ - specs_e2e/rails_8/test-results/.last-run.json
403
+ - specs_e2e/rails_8/test.sh
404
+ - specs_e2e/rails_8/test/application_system_test_case.rb
405
+ - specs_e2e/rails_8/test/controllers/posts_controller_test.rb
406
+ - specs_e2e/rails_8/test/cypress_fixtures/posts.yml
407
+ - specs_e2e/rails_8/test/fixtures/posts.yml
408
+ - specs_e2e/rails_8/test/models/post_test.rb
409
+ - specs_e2e/rails_8/test/test_helper.rb
410
+ - specs_e2e/rails_8/vendor/.keep
411
+ - specs_e2e/rails_8/vendor/javascript/.keep
315
412
  - tmp/pids/.gitkeep
316
413
  homepage: http://github.com/shakacode/cypress-on-rails
317
414
  licenses: []
@@ -337,8 +434,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
337
434
  - !ruby/object:Gem::Version
338
435
  version: '0'
339
436
  requirements: []
340
- rubygems_version: 3.4.7
341
- signing_key:
437
+ rubygems_version: 3.6.7
342
438
  specification_version: 4
343
439
  summary: Integrates cypress with rails or rack applications
344
440
  test_files: []
@@ -1,73 +0,0 @@
1
- require 'json'
2
- require 'rack'
3
- require 'cypress_on_rails/middleware_config'
4
-
5
- module CypressOnRails
6
- # Middleware to handle vcr
7
- class VCRMiddleware
8
- include MiddlewareConfig
9
-
10
- def initialize(app, vcr = nil)
11
- @app = app
12
- @vcr = vcr
13
- @first_call = false
14
- end
15
-
16
- def call(env)
17
- request = Rack::Request.new(env)
18
- if request.path.start_with?('/__e2e__/vcr/insert')
19
- configuration.tagged_logged { handle_insert(request) }
20
- elsif request.path.start_with?('/__e2e__/vcr/eject')
21
- configuration.tagged_logged { handle_eject }
22
- else
23
- do_first_call unless @first_call
24
- @app.call(env)
25
- end
26
- end
27
-
28
- private
29
-
30
- def handle_insert(req)
31
- WebMock.enable! if defined?(WebMock)
32
- vcr.turn_on!
33
- body = JSON.parse(req.body.read)
34
- logger.info "vcr insert cassette: #{body}"
35
- cassette_name = body[0]
36
- options = (body[1] || {}).symbolize_keys
37
- options[:record] = options[:record].to_sym if options[:record]
38
- options[:match_requests_on] = options[:match_requests_on].map(&:to_sym) if options[:match_requests_on]
39
- options[:serialize_with] = options[:serialize_with].to_sym if options[:serialize_with]
40
- options[:persist_with] = options[:persist_with].to_sym if options[:persist_with]
41
- vcr.insert_cassette(cassette_name, options)
42
- [201, {'Content-Type' => 'application/json'}, [{'message': 'OK'}.to_json]]
43
- rescue LoadError, ArgumentError => e
44
- [501, {'Content-Type' => 'application/json'}, [{'message': e.message}.to_json]]
45
- end
46
-
47
- def handle_eject
48
- logger.info "vcr eject cassette"
49
- vcr.eject_cassette
50
- do_first_call
51
- [201, {'Content-Type' => 'application/json'}, [{'message': 'OK'}.to_json]]
52
- rescue LoadError, ArgumentError => e
53
- [501, {'Content-Type' => 'application/json'}, [{'message': e.message}.to_json]]
54
- end
55
-
56
- def vcr
57
- return @vcr if @vcr
58
- require 'vcr'
59
- VCR.configure do |config|
60
- config.cassette_library_dir = "#{configuration.install_folder}/fixtures/vcr_cassettes"
61
- end
62
- @vcr = VCR
63
- end
64
-
65
- def do_first_call
66
- @first_call = true
67
- vcr.turn_off!
68
- WebMock.disable! if defined?(WebMock)
69
- rescue LoadError
70
- # nop
71
- end
72
- end
73
- end